<template>
  <div :class="switchValue ? 'home_dark' : 'home_light'">
    <header-com :index="index"></header-com>
    <div class="main">
      <div class="left"></div>
      <div class="right"></div>
      <div class="centent">
        <el-row :gutter="20">
          <el-col :span="24">
            <div class="time_search">
              <div class="weather_time">
                <div>{{ dateValue }}</div>
                <div class="weather">
                  <img v-if="weatherImg == '阴'" src="../assets/image/icon-yin.png" alt />
                  <img v-if="weatherImg == '下雨'" src="../assets/image/icon-xiayu.png" alt />
                  <img v-if="weatherImg == '晴'" src="../assets/image/icon-qing.png" alt />
                  <img v-if="weatherImg == '多云'" src="../assets/image/icon-duoyun.png" alt />
                  <span>{{ airValue }}</span>
                </div>
              </div>
              <div class="search">
                <el-input
                  placeholder="请输入内容"
                  v-model="searchValue"
                  class="input-with-select"
                  @keyup.enter.native="search"
                >
                  <el-button slot="append" icon="el-icon-search" @click="search"></el-button>
                </el-input>
                <ul class="Hot_words">
                  <li>常用搜索:</li>
                  <li
                    :class="bgc == item ? 'active' : ''"
                    v-for="(item, index) in keyWords"
                    :key="index"
                    @click="bgc = item"
                  >{{ item }}</li>
                </ul>
              </div>
            </div>
          </el-col>
        </el-row>
        <el-row :gutter="10">
          <el-col :span="18">
            <!-- 待办事项/公文处理非均无数据 -->
            <el-row :gutter="10">
              <el-col :span="8">
                <div class="todoList">
                  <el-tabs v-model="activeName">
                    <el-tab-pane label="待办事项" name="待办事项">
                      <ul v-if="systemCount.length > 0" style="max-height: 290px; overflow-y: auto">
                        <li
                          v-for="(item, index) in systemCount"
                          :key="index"
                          @click="xtdhClick(item.link, item.sysId)"
                        >
                          <div class="text_title">
                            {{ item.name }}
                            <i class="el-icon-caret-right"></i>
                          </div>
                          <div class="text_count">
                            <img :src="item.img" alt />
                            <span>&nbsp;{{ item.count }}</span>
                            <i>&nbsp;&nbsp;条</i>
                          </div>
                        </li>
                      </ul>
                      <div class="empty" v-else style="background-size: 280px 136px">
                        <img
                          :src="
                            switchValue
                              ? require('../assets/image/empty.png')
                              : require('../assets/image/empty_black.png')
                          "
                          alt
                          width="75"
                          height="75"
                        />
                        <div>暂无待办事项</div>
                      </div>
                    </el-tab-pane>
                  </el-tabs>
                </div>
              </el-col>
              <el-col :span="16">
                <div class="processing">
                  <div class="switch">
                    <div :class="processShow ? 'switch_deal' : 'switch_finish'" @click="clickdb">待办</div>
                    <div
                      :class="
                        processShow == false ? 'switch_deal' : 'switch_finish'
                      "
                      @click="finishedClick"
                    >最近已办</div>
                  </div>
                  <el-tabs v-model="activeNameGwcl">
                    <el-tab-pane label="公文处理" name="公文处理">
                      <div v-if="processShow">
                        <div v-if="processData.length != 0">
                          <ul>
                            <li
                              v-for="(item, index) in processData"
                              :key="index"
                              @click="
                                detailLink(
                                  '公文待办页面',
                                  item.STEP,
                                  item.IID,
                                  item.WIID,
                                  item.WNAME
                                )
                              "
                              class="liHove"
                            >
                              <el-tag v-if="item.EMERGY == '普通'">传阅</el-tag>
                              <el-tag type="danger" v-if="item.EMERGY == '特急'">特急</el-tag>
                              <el-tag type="warning" v-if="item.EMERGY == '加急'">加急</el-tag>
                              <span class="text_process">{{ item.TITLE ? item.TITLE : "" }}</span>
                              <span class="time_process">
                                接收时间：{{
                                item.ATIME ? item.ATIME.split(" ")[0] : ""
                                }}
                              </span>
                            </li>
                          </ul>
                          <div class="more_process" @click="handleLink('公文待办页面')">更多</div>
                        </div>
                        <div class="empty" v-else>
                          <img
                            :src="
                              switchValue
                                ? require('../assets/image/empty.png')
                                : require('../assets/image/empty_black.png')
                            "
                            alt
                            width="75"
                            height="75"
                          />
                          <div>暂无待办事项</div>
                        </div>
                      </div>
                      <div v-else>
                        <div v-if="finishedData.length != 0">
                          <ul>
                            <li
                              v-for="(item, index) in finishedData"
                              :key="index"
                              @click="
                                finishedLink(
                                  '公文待办页面',
                                  item.STEP,
                                  item.IID,
                                  item.WIID,
                                  item.WNAME
                                )
                              "
                              class="liHove"
                            >
                              <el-tag v-if="item.EMERGY == '普通'">传阅</el-tag>
                              <el-tag type="danger" v-if="item.EMERGY == '特急'">特急</el-tag>
                              <el-tag type="warning" v-if="item.EMERGY == '加急'">加急</el-tag>
                              <span class="text_process">{{ item.NAME }}</span>
                              <span class="time_process">
                                完成时间：{{
                                item.ACCEPTED_TIME.split(" ")[0]
                                }}
                              </span>
                            </li>
                          </ul>
                          <div class="more_process" @click="handleLink('最近已完成-更多')">更多</div>
                        </div>
                        <div class="empty" v-else>
                          <img
                            :src="
                              switchValue
                                ? require('../assets/image/empty.png')
                                : require('../assets/image/empty_black.png')
                            "
                            alt
                            width="75"
                            height="75"
                          />
                          <div>暂无待办事项</div>
                        </div>
                      </div>
                    </el-tab-pane>
                  </el-tabs>
                </div>
              </el-col>
            </el-row>

            <el-row :gutter="20">
              <el-col :span="24">
                <div class="platform">
                  <el-carousel height="106px">
                    <el-carousel-item>
                      <img src="../assets/image/图片18.png" alt />
                    </el-carousel-item>
                  </el-carousel>
                  <div class="platform_words">
                    <div class="platform_text">国 土 空 间 基 础 信 息 平 台</div>
                    <div class="line"></div>
                    <ul>
                      <li @click="handleLink('资源申请')">资源申请</li>
                      <li @click="handleLink('地图应用')">地图应用</li>
                      <li @click="handleLink('空间分析')">空间分析</li>
                      <li @click="handleLink('应用监控')">应用监控</li>
                    </ul>
                  </div>
                </div>
              </el-col>
            </el-row>

            <el-row :gutter="20">
              <el-col :span="12">
                <div class="importantNews">
                  <el-tabs v-model="currentTabName" @tab-click="handleClickNew">
                    <el-tab-pane label="要闻推荐" name="要闻推荐">
                      <ul class="news">
                        <li @click="detailClickLink('1', firstData.ID)">
                          <el-carousel height="130px">
                            <el-carousel-item v-for="(item, index) in imgUrl" :key="index">
                              <el-image
                                :src="item.FASTFILEURL"
                                :fit="'fit'"
                                style="width: 100%; height: 100%"
                              ></el-image>
                            </el-carousel-item>
                          </el-carousel>

                          <div class="txt">
                            <h5>市规划和自然资源局召开会议</h5>
                            <p class>{{ firstData.TITLE }}</p>
                            <span class>{{ firstData.CREATEDATE }}</span>
                          </div>
                        </li>
                        <li
                          v-for="(item, index) in newsData"
                          :key="index"
                          @click="detailClickLink('1', item.ID)"
                          class="liHove"
                        >
                          <span class="text_importantNews">
                            {{
                            item.TITLE
                            }}
                          </span>
                          <span class="time_importantNews">
                            {{
                            item.CREATEDATE
                            }}
                          </span>
                        </li>
                      </ul>
                      <div class="more_process" @click="newsLink('1')">更多</div>
                    </el-tab-pane>
                    <el-tab-pane label="部门动态" name="部门动态">
                      <ul class="others">
                        <li
                          v-for="(item, index) in bmData"
                          :key="index"
                          @click="detailClickLink('9', item.ID)"
                          class="liHove"
                        >
                          <span class="text_importantNews">
                            {{
                            item.TITLE
                            }}
                          </span>
                          <span class="time_importantNews">
                            {{
                            item.CREATEDATE
                            }}
                          </span>
                        </li>
                      </ul>
                      <div class="more_process" @click="newsLink('9')">更多</div>
                    </el-tab-pane>
                    <el-tab-pane label="区（市）县局" name="区（市）县局">
                      <ul class="others">
                        <li
                          v-for="(item, index) in qxData"
                          :key="index"
                          @click="detailClickLink('区(市)2', item.ID)"
                          class="liHove"
                        >
                          <span class="text_importantNews">
                            {{
                            item.TITLE
                            }}
                          </span>
                          <span class="time_importantNews">
                            {{
                            item.CREATEDATE
                            }}
                          </span>
                        </li>
                      </ul>
                      <div class="more_process" @click="newsLink('2')">更多</div>
                    </el-tab-pane>
                  </el-tabs>
                </div>
              </el-col>
              <el-col :span="12">
                <div class="information">
                  <el-tabs v-model="currentName">
                    <el-tab-pane label="简报信息" name="简报信息">
                      <ul>
                        <li
                          v-for="(item, index) in jbData"
                          :key="index"
                          @click="detailClickLink('4', item.ID)"
                          class="liHove"
                        >
                          <span class="text_information">{{ item.TITLE }}</span>
                          <span class="time_information">
                            {{
                            item.CREATEDATE
                            }}
                          </span>
                        </li>
                      </ul>
                      <div class="more_process" @click="newsLink('4')">更多</div>
                    </el-tab-pane>
                    <el-tab-pane label="参阅信息" name="参阅信息">
                      <div v-if="cyData.length != 0">
                        <ul>
                          <li
                            v-for="(item, index) in cyData"
                            :key="index"
                            @click="detailClickLink('6', item.ID)"
                            class="liHove"
                          >
                            <span class="text_information">
                              {{
                              item.TITLE
                              }}
                            </span>
                            <span class="time_information">
                              {{
                              item.CREATEDATE
                              }}
                            </span>
                          </li>
                        </ul>
                        <div class="more_process" @click="newsLink('6')">更多</div>
                      </div>
                      <div class="empty" v-else>
                        <img
                          :src="
                            switchValue
                              ? require('../assets/image/empty.png')
                              : require('../assets/image/empty_black.png')
                          "
                          alt
                          width="75"
                          height="75"
                        />
                        <div>暂无数据</div>
                      </div>
                    </el-tab-pane>
                    <el-tab-pane label="内部公示" name="内部公示">
                      <ul>
                        <li
                          v-for="(item, index) in nbData"
                          :key="index"
                          @click="detailClickLink('5', item.ID)"
                          class="liHove"
                        >
                          <span class="text_information">{{ item.TITLE }}</span>
                          <span class="time_information">
                            {{
                            item.CREATE_TIME.split(" ")[0]
                            }}
                          </span>
                        </li>
                      </ul>
                      <div class="more_process" @click="newsLink('5')">更多</div>
                    </el-tab-pane>
                    <el-tab-pane label="人事任免" name="人事任免">
                      <ul>
                        <li
                          v-for="(item, index) in rsData"
                          :key="index"
                          @click="detailClickLink('8', item.ID)"
                          class="liHove"
                        >
                          <span class="text_information">{{ item.TITLE }}</span>
                          <span class="time_information">
                            {{
                            item.CREATEDATE
                            }}
                          </span>
                        </li>
                      </ul>
                      <div class="more_process" @click="newsLink('8')">更多</div>
                    </el-tab-pane>
                    <el-tab-pane label="公示公告" name="公示公告">
                      <ul>
                        <li
                          v-for="(item, index) in gsData"
                          :key="index"
                          @click="detailClickLink('7', item.ID)"
                          class="liHove"
                        >
                          <span class="text_information">{{ item.TITLE }}</span>
                          <span class="time_information">
                            {{
                            item.CREATEDATE
                            }}
                          </span>
                        </li>
                      </ul>
                      <div class="more_process" @click="newsLink('7')">更多</div>
                    </el-tab-pane>
                  </el-tabs>
                </div>
              </el-col>
            </el-row>
          </el-col>
          <el-col :span="6">
            <div class="system_navigation">
              <el-tabs v-model="activeNameXtdh" class="xtdh_padding">
                <el-tab-pane label="系统导航" name="系统导航">
                  <ul>
                    <li
                      class="grid"
                      v-for="(item, index) in xtdhData.currentPageData"
                      :key="index"
                      @click="xtdhClick(item.link, item.sysId)"
                    >
                      <div :class="['grid_box', item.bgColor]">
                        <img :src="switchValue ? item.lightImg : item.darkImg" alt />
                      </div>
                      {{ item.name }}
                    </li>
                  </ul>
                </el-tab-pane>
              </el-tabs>
              <span class="setting">设置</span>
              <div
                class="left-pagination-btn"
                @click="systemNavigationPrev"
                v-if="xtdhData.curPage != 1"
              >
                <span class="el-icon-arrow-left"></span>
              </div>
              <div
                class="right-pagination-btn"
                @click="systemNavigationNext"
                v-if="xtdhData.curPage < xtdhData.totalPage"
              >
                <span class="el-icon-arrow-right"></span>
              </div>
            </div>
          </el-col>
        </el-row>
        <el-row :gutter="20" class="specialColumn" style="padding: 0px" id="imgDivId">
          <div id="d1">
            <div id="d12">
              <div class="d121 d120" v-for="(item, index) in linkImgUrl" :key="index">
                <a :href="item.linkUrl" target="_blank">
                  <div class="ddd">
                    <img style="height: 121px" class="dimg" :src="item.src" alt />
                  </div>
                </a>
              </div>
            </div>
          </div>
        </el-row>
        <div class="title">
          <div class="title_text">
            <span></span>确权登记
          </div>
          <div class="expand_statistics" @click="opCloChart('qqdhRef')">
            展开统计
            <img src="../assets/image/图标 43.svg" alt />
          </div>
          <div style="clear: both"></div>
        </div>
        <el-row :gutter="7" v-show="isQqdhRef">
          <el-col :span="6">
            <div class="registration">
              <div style="color: #fff; font-size: 18px; margin-top: 10px" class="jrslBox">
                <div>
                  <div class="chartNum">
                    <h3 class="orderTitle">今日受理</h3>
                    <div class="box-item">
                      <li
                        :class="{
                          'number-item': !isNaN(item),
                          'mark-item': isNaN(item),
                        }"
                        v-for="(item, index) in orderNum"
                        :key="index"
                      >
                        <span v-if="!isNaN(item)">
                          <i ref="numberItem">0123456789</i>
                        </span>
                        <span class="comma" v-else>{{ item }}</span>
                      </li>
                    </div>
                  </div>
                </div>
              </div>
              <ul>
                <li>
                  <div>{{ jrslData.newData["一圈层"]? jrslData.newData["一圈层"]:0}}件</div>
                  <span>一圈层(5+2)</span>
                </li>
                <li>
                  <div>{{ jrslData.newData["二圈层"]?jrslData.newData["二圈层"] :0 }}件</div>
                  <span>二圈层(7)</span>
                </li>
                <li>
                  <div>{{ jrslData.newData["三圈层"]?jrslData.newData["三圈层"]:0 }}件</div>
                  <span>三圈层(8)</span>
                </li>
              </ul>
              <div class="registration_grid">
                <el-tag v-for="item in bldData" :key="item['办理点']">
                  {{ item["办理点"] }}：
                  <span>{{ item["等待数量"] }}人等待</span>
                </el-tag>
              </div>
            </div>
          </el-col>
          <el-col :span="18">
            <el-row>
              <el-col :span="24">
                <div class="register">
                  <el-tabs v-model="activeNameSldb" @tab-click="registerClick">
                    <el-tab-pane label="耗时异常" name="耗时异常" style="position: relative">
                      <div class="dxyw-module-box">
                        <ul class="dxyw-list-box">
                          <li class="dxyw-list-item" v-for="(item,index) in hsycData" :key="index">
                            <p class="dxyw-name">{{item.name}}</p>
                            <div class="dxyw-count-box">
                              <div>
                                <p class="count color_red">{{item['超期办结']}}</p>
                                <p class="text">超期办结</p>
                              </div>
                              <div>
                                <p class="count color_orange">{{item['在办积压']}}</p>
                                <p class="text">在办积压</p>
                              </div>
                            </div>
                          </li>
                          <li
                            class="list"
                            v-for="(item,index) in (row-hsycData.length%row)"
                            :key="index"
                            v-if="(hsycData.length%row) > 0"
                          ></li>
                        </ul>
                      </div>
                    </el-tab-pane>
                    <el-tab-pane label="典型业务" name="典型业务" style="position: relative">
                      <div id="registerddxyw_echart"></div>
                      <div class="time">统计时间：{{ beforeMounth }}</div>
                    </el-tab-pane>
                    <el-tab-pane label="受理登簿" name="受理登簿" style="position: relative">
                      <div id="register_echart"></div>
                      <div class="time">统计时间：{{ sldbTimer }}</div>
                      <div class="date">
                        <span @click="initRegister(sldbDatadate, 0)">日</span>
                        <span @click="initRegister(sldbDatamonth, 1)">月</span>
                        <span @click="initRegister(sldbDatayear, 2)">年</span>
                      </div>
                    </el-tab-pane>
                  </el-tabs>
                </div>
              </el-col>
            </el-row>
          </el-col>
        </el-row>
        <div class="title">
          <div class="title_text">
            <span></span>工建改革
          </div>
          <div class="expand_statistics" @click="opCloChart('gjggRef')">
            展开统计
            <img src="../assets/image/图标 43.svg" alt />
          </div>
          <div style="clear: both"></div>
        </div>
        <el-row :gutter="7" v-show="isGjggRef">
          <el-col :span="6">
            <div class="reform">
              <div class="tag_registration">
                <div class="title_registration">本月在办情况:</div>
                <div class="teg_flex">
                  <div class="tag">
                    <span class="left_text">在办数</span>
                    <span class="right_count">{{gjggdqzbqk.length>0?gjggdqzbqk[0]['办理数']:0}}</span>
                  </div>

                  <div class="tag">
                    <span class="left_text">挂起数</span>
                    <span class="right_count">{{gjggdqzbqk.length>0?gjggdqzbqk[0]['挂起数']:0}}</span>
                  </div>
                </div>
                <div class="teg_flex">
                  <div class="tag">
                    <span class="left_text">退件数</span>
                    <span class="right_count">{{gjggdqzbqk.length>0?gjggdqzbqk[0]['退件数']:0}}</span>
                  </div>
                  <div class="tag">
                    <span class="left_text">超时数</span>
                    <span
                      class="right_count color_red"
                    >{{gjggdqzbqk.length>0?gjggdqzbqk[0]['超时数']:0}}</span>
                  </div>
                </div>
                <div class="tag">
                  <span class="left_text">用地面积</span>
                  <span
                    class="right_count"
                  >{{gjggdqzbqk.length>0?gjggdqzbqk[0]['用地面积'].toFixed(2):0}}公顷</span>
                </div>
                <div class="tag">
                  <span class="left_text">建筑面积</span>
                  <span
                    class="right_count"
                  >{{gjggdqzbqk.length>0?gjggdqzbqk[0]['建筑面积'].toFixed(2):0}}公顷</span>
                </div>
              </div>

              <div class="tag_registration">
                <div class="title_registration">本月发证（函）情况：</div>
                <template>
                  <div class="tag">
                    <span class="left_text">发证数</span>
                    <span class="right_count">{{fzstotal}}本</span>
                  </div>
                  <div class="tag" v-if="mhbygjfzJzl.length>0">
                    <span class="left_text">{{mhbygjfzJzl[0].TYPE}}</span>
                    <span class="right_count">{{mhbygjfzJzl[0].COUNT}}本</span>
                  </div>
                  <div class="tag tag_zhcc" v-if="mhbygjfzJzl.length>0">
                    <span class="left_text">· 报建方案技术复核抽中</span>
                    <span class="right_count">{{gjjscc[0].COUNT}}本</span>
                  </div>
                  <div class="tag" v-for="(item,index) in mhbygjfz" :key="index">
                    <span class="left_text">{{item.TYPE}}</span>
                    <span class="right_count">{{item.COUNT}}本</span>
                  </div>
                  <div class="tag">
                    <span class="left_text">平均办理时间</span>
                    <span class="right_count color_orange">{{pjblsj}}天</span>
                  </div>
                </template>
              </div>
            </div>
          </el-col>
          <el-col :span="18">
            <el-row :gutter="7">
              <el-col :span="24">
                <div class="architecture">
                  <el-form :inline="true" :model="formInline" class="demo-form-inline">
                    <el-form-item label="行政区">
                      <el-select v-model="formInline.region" placeholder @change="select">
                        <el-option
                          v-for="item in regien"
                          :key="item.value"
                          :label="item.name"
                          :value="item.value"
                        ></el-option>
                      </el-select>
                    </el-form-item>
                    <el-form-item label="统计时间">
                      <el-select v-model="formInline.time" placeholder @change="select">
                        <el-option label="截止昨日" value="0"></el-option>
                        <el-option label="最近一月" value="1"></el-option>
                        <el-option label="最近一年" value="2"></el-option>
                      </el-select>
                    </el-form-item>
                  </el-form>
                  <el-tabs v-model="activeNameJzl">
                    <el-tab-pane label="建筑类" name="建筑类">
                      <ul class="item_architecture">
                        <li v-for="(item, index) in gjggJzlData" :key="index">
                          <div class="header_architecture">{{ item.name }}</div>
                          <div class="body_architecture">
                            <div class="project">项目({{ item.PROJECT_NUM }})</div>
                            <p class="project_item" v-for="(i, ind) in item['项目']" :key="ind">
                              {{ i.name }}
                              <span @click="gjggLink">{{ i.count }}</span>
                            </p>
                          </div>
                          <div class="body_architect">
                            <div class="project">项目({{ item.HANDLE_NUM }})</div>
                            <p v-for="(ele, idx) in item['在办件']" :key="idx">
                              {{ ele.name }}
                              <span
                                :class="ele.name=='即将超期'?'project_jjcq':'project_ycq'"
                                @click="gjggLink"
                              >{{ ele.count }}</span>
                            </p>
                          </div>
                        </li>
                      </ul>
                    </el-tab-pane>
                  </el-tabs>
                </div>
              </el-col>
            </el-row>
            <el-row>
              <el-col :span="24">
                <div class="handling">
                  <el-tabs v-model="activeNameBjtj">
                    <el-tab-pane label="市政类" name="市政类">
                      <ul class="item_architecture">
                        <li v-for="(item, index) in gjggSzlData" :key="index">
                          <div class="header_architecture">{{ item.name }}</div>
                          <div class="body_architecture">
                            <div class="project">项目({{ item.PROJECT_NUM }})</div>
                            <p class="project_item" v-for="(i, ind) in item['项目']" :key="ind">
                              {{ i.name }}
                              <span @click="gjggLink">{{ i.count }}</span>
                            </p>
                          </div>
                          <div class="body_architect">
                            <div class="project">项目({{ item.HANDLE_NUM }})</div>
                            <p v-for="(ele, idx) in item['在办件']" :key="idx">
                              {{ ele.name }}
                              <span
                                :class="ele.name=='即将超期'?'project_jjcq':'project_ycq'"
                                @click="gjggLink"
                              >{{ ele.count }}</span>
                            </p>
                          </div>
                        </li>
                      </ul>
                    </el-tab-pane>
                  </el-tabs>
                </div>
              </el-col>
            </el-row>
          </el-col>
        </el-row>
        <div class="title">
          <div class="title_text">
            <span></span>建设用地报批与监管
          </div>
          <div class="expand_statistics" @click="opCloChart('jsydbpjgRef')">
            展开统计
            <img src="../assets/image/图标 43.svg" alt />
          </div>
          <div style="clear: both"></div>
        </div>
        <el-row :gutter="7" style="margin-bottom: 0px" v-show="isJsydbpjgRef">
          <el-col :span="24">
            <el-row :gutter="7">
              <el-col :span="15">
                <div class="dealtWith">
                  <el-tabs v-model="activeNameDbyw">
                    <el-tab-pane label="处室会审情况" name="处室会审情况">
                      <div class="cshs-module-box">
                        <ul class="cshs-list-box">
                          <li
                            class="cshs-list-item"
                            v-for="item in jsydbpData.cshs"
                            :key="item.name"
                            :class="item['会审数']==0?'color_gray':''"
                          >
                            <div class="cshs-name" :class="item['会审数']==0?'color_gray':''">
                              <p>{{item['处室名称']}}</p>
                            </div>
                            <div class="cshs-val">
                              <div>
                                <p>{{item['会审数']}}</p>
                                <p>未完成数</p>
                              </div>
                              <div>
                                <p>{{item['会审时间']}}</p>
                                <p>平均耗时</p>
                              </div>
                            </div>
                          </li>
                        </ul>
                      </div>
                    </el-tab-pane>
                  </el-tabs>
                </div>
              </el-col>
              <el-col :span="9">
                <div class="dealtWith">
                  <el-tabs v-model="activeNameGzbj">
                    <el-tab-pane label="办理跟踪统计" name="报件跟踪统计">
                      <ul>
                        <li class="deal_grid">
                          <div class="deal_grid_box">
                            <img src="../assets/image/图标 508.svg" alt />
                          </div>
                          <div class="deal_text">
                            <div
                              class="deal_count"
                            >{{jsydbpData.blgztj.length>0? jsydbpData.blgztj[0]['待组卷']:0}}</div>
                            <div class="deal_words">待组卷</div>
                          </div>
                          <i class="el-icon-caret-right"></i>
                        </li>
                        <li class="deal_grid">
                          <div class="deal_grid_box">
                            <img src="../assets/image/图标 508.svg" alt />
                          </div>
                          <div class="deal_text">
                            <div
                              class="deal_count"
                            >{{jsydbpData.blgztj.length>0? jsydbpData.blgztj[0]['待受理']:0}}</div>
                            <div class="deal_words">待受理</div>
                          </div>
                          <i class="el-icon-caret-right"></i>
                        </li>
                        <li class="deal_grid">
                          <div class="deal_grid_box">
                            <img src="../assets/image/图标 508.svg" alt />
                          </div>
                          <div class="deal_text">
                            <div
                              class="deal_count"
                            >{{jsydbpData.blgztj.length>0? jsydbpData.blgztj[0]['待审核']:0}}</div>
                            <div class="deal_words">待审核</div>
                          </div>
                          <i class="el-icon-caret-right"></i>
                        </li>
                        <!-- <li class="deal_grid">
                          <div class="deal_grid_box">
                            <img src="../assets/image/图标 508.svg" alt />
                          </div>
                          <div class="deal_text">
                            <div class="deal_count">88%</div>
                            <div class="deal_words">退件/补正率</div>
                          </div>
                          <i class="el-icon-caret-right" style="margin-left: 26px"></i>
                        </li>-->
                      </ul>
                    </el-tab-pane>
                  </el-tabs>
                  <div class="blhs" @click="handleClickblhs('建设用地-办理耗时统计')">办理耗时统计</div>
                </div>
              </el-col>
            </el-row>
            <el-row>
              <el-col :span="24">
                <div class="jointTrial">
                  <el-tabs v-model="activeNameCshs" @tab-click="jsydClick">
                    <el-tab-pane label="报件跟踪" name="报件跟踪">
                      <div id="jointTrialBjgz_echart"></div>
                      <div class="time">截止时间：{{ yesterday }}</div>
                    </el-tab-pane>
                    <el-tab-pane label="上报省厅情况" name="上报客厅情况">
                      <div id="jointTrialSbst_echart"></div>
                      <div class="time">截止时间：{{ yesterday }}</div>
                    </el-tab-pane>
                    <el-tab-pane label="报件质量" name="报件质量">
                      <div id="jointTrialBjzl_echart"></div>
                      <div class="time">截止时间：{{ yesterday }}</div>
                    </el-tab-pane>
                  </el-tabs>
                </div>
              </el-col>
            </el-row>
          </el-col>
        </el-row>
        <div class="title">
          <div class="title_text">
            <span></span>综合事务
          </div>
          <div class="expand_statistics" @click="opCloChart('zhyw')">
            展开统计
            <img src="../assets/image/图标 43.svg" alt />
          </div>
          <div style="clear: both"></div>
        </div>
        <el-row :gutter="7" v-show="isZhywRef">
          <el-col :span="6">
            <div class="registration_business">
              <div class="tag_registration">
                <div class="jryp-box">
                  <p>今日阅批：</p>
                  <div class="jryp-number-box">
                    <span v-for="(item,index) in String(jryp).split('')" :key="index">{{item}}</span>
                  </div>
                  <p>件·次</p>
                </div>
                <div class="jryp-footer-box">
                  <div class="jryp-item">
                    <p>{{ bysl }}件</p>
                    <p>本月收文</p>
                  </div>
                  <div class="jryp-item">
                    <p>{{ cqwbj }}件</p>
                    <p>到期未办</p>
                  </div>
                </div>
              </div>
              <div class="tag_registration">
                <div class="title_registration">督办</div>
                <div class="jryp-module-box">
                  <div class="first-label-box">
                    <p>总计未办结：</p>
                    <p>
                      {{dbJrsl['总计未办结']}}项
                      <span></span>
                    </p>
                  </div>
                  <div class="erji-label-box">
                    <p>超期未办：</p>
                    <p>{{dbJrsl['总计超期未办结']}}项</p>
                  </div>
                </div>
              </div>
              <div class="tag_registration">
                <div class="jryp-module-box">
                  <div class="first-label-box">
                    <p>本月新增：</p>
                    <p>
                      {{duBan.length>0?duBan[0]['新增立项']:0}}项
                      <span></span>
                    </p>
                  </div>
                  <div class="erji-label-box">
                    <p>处室签收：</p>
                    <p>{{duBan.length>0?duBan[0]['目标签收']:0}}项</p>
                  </div>
                </div>
              </div>
              <div class="tag_registration" style="border:0">
                <div class="jryp-module-box">
                  <div class="first-label-box">
                    <p>本月已办结：</p>
                    <p>
                      {{duBan.length>0?duBan[0]['事项办结']:0}}项
                      <span></span>
                    </p>
                  </div>
                </div>
              </div>
            </div>
          </el-col>
          <el-col :span="18">
            <el-row>
              <el-col :span="24">
                <div class="statistics">
                  <el-tabs v-model="activeNameZhyw" @tab-click="zhywClick">
                    <el-tab-pane label="发文统计" name="发文统计" style="position: relative">
                      <div id="statisticsfwtj_echart"></div>
                      <div class="time">统计时间：{{ fwtjTime }}</div>
                      <div class="date">
                        <span @click="getBarChartStaticDatafwtj('fwtj_month')">月</span>
                        <span @click="getBarChartStaticDatafwtj('fwtj_year')">年</span>
                        <span @click="getBarChartStaticDatafwtj('fwtj')">全</span>
                      </div>
                    </el-tab-pane>
                    <el-tab-pane label="移动端" name="移动端" style="position: relative">
                      <div id="statisticsydd_echart"></div>
                      <div class="time">统计时间：{{ yddTime }}</div>
                      <div class="date">
                        <span @click="getBarChartStaticDataydd('mobileSystem_month')">月</span>
                        <span @click="getBarChartStaticDataydd('mobileSystem_year')">年</span>
                        <span @click="getBarChartStaticDataydd('mobileSystem')">全</span>
                      </div>
                    </el-tab-pane>
                  </el-tabs>
                </div>
              </el-col>
            </el-row>
          </el-col>
        </el-row>
      </div>
      <el-dialog title="选择用户" :visible.sync="dialogFormVisible" width="30%">
        <el-select v-model="roleID" placeholder="请选择登录系统用户" style="width: 70%">
          <el-option
            v-for="(item, index) in userList"
            :key="index"
            :label="item.LOGIN_NAME"
            :value="item.USERID"
          ></el-option>
        </el-select>
        <div slot="footer" class="dialog-footer">
          <el-button @click="dialogFormVisible = false">取 消</el-button>
          <el-button type="primary" @click="GetSystemUrl('', '')">确 定</el-button>
        </div>
      </el-dialog>
    </div>

    <footerCom></footerCom>

    <div class="fixd_menu">
      <ul>
        <li @click="$router.push('/userInfo')">
          <img
            :src="
              switchValue
                ? require('../assets/image/图标901.svg')
                : require('../assets/image/图标 9012.svg')
            "
            alt
          />
          用户信息
        </li>
        <li @click="$router.push('/helpcenter')">
          <img
            :src="
              switchValue
                ? require('../assets/image/图标 900.svg')
                : require('../assets/image/图标 9002.svg')
            "
            alt
          />
          服务指南
        </li>
        <li @click="$router.push('/Opinions')">
          <img
            :src="
              switchValue
                ? require('../assets/image/图标 904.svg')
                : require('../assets/image/图标 9042.svg')
            "
            alt
          />
          意见建议
        </li>
        <li>
          <el-popover placement="right" width="150" trigger="hover">
            <el-switch
              style="display: block"
              v-model="switchValue"
              active-color="#eee"
              inactive-color="#000"
              active-text="浅色"
              inactive-text="深色"
              @change="handleSwitch"
            ></el-switch>
            <span slot="reference">
              <img
                :src="
                  switchValue
                    ? require('../assets/image/图标 905.svg')
                    : require('../assets/image/图标 905 (1).svg')
                "
                alt
              />
              主题切换
            </span>
          </el-popover>
        </li>
        <li class="top" @click="gotoTop()">
          <img
            :src="
              switchValue
                ? require('../assets/image/图标 907.svg')
                : require('../assets/image/图标9072.svg')
            "
            alt
          />
          返回顶部
        </li>
      </ul>
    </div>
  </div>
</template>

<script>
import * as echarts from "echarts";
import footerCom from "./footerCom.vue"
import $ from "jquery"; //引入jquery，否则document.getElementById为null
import HeaderCom from './headerCom.vue';
export default {
  components: {
    footerCom,
    HeaderCom
  },
  data() {
    return {
      row: 5,
      dialogFormVisible: false,
      roleID: "",
      index:true,
      userList: null,
      state: "",
      orderNum: ["0", "0", "0", ",", "0", "0", "0"], // 默认订单总数
      newNumber: 0,
      imgStartTimer: null,
      timerDb: null,
      imgWidth: 0,
      imgHeigth: 0,
      moveLength: 0,
      imgCarouselTimer: null,
      bgc: "全部",
      keyWords: [
        "全部",
        "收文",
        "发文",
        "政策法规",
        "信息"

        // "市局要闻",
        // "区县要闻",
        // "会议通知"
      ],
      bgColor: "",
      activeNameGwcl: "公文处理",
      activeEmpty: "待办事项",
      activeNameXtdh: "系统导航",
      className: "home_light",
      currentName: "简报信息",
      activeName: "待办事项",
      activeTabName: "“一窗业务”受理情况",
      currentTabName: "要闻推荐",
      activeNameSy: "“一窗业务”使用情况",
      activeNameSldb: "耗时异常",
      activeNameJzl: "建筑类",
      activeNameBjtj: "市政类",
      activeNameDbyw: "处室会审情况",
      activeNameGzbj: "报件跟踪统计",
      activeNameCshs: "报件跟踪",
      activeNameZhyw: "发文统计",
      formInline: {
        time: "2",
        region: 510100
      },
      queryCriteria: false,
      switchValue: false,
      searchValue: "",
      navigatorLink: [],
      interfaceName: "antu.newportal-zjx.provider",
      userId: localStorage.getItem("USER_ID"),
      // userId: "14E185BA-A88N-763T-D2BU-CD3321A9227D",
      processData: [],
      finishedData: [],
      processShow: true,
      systemCount: [],
      imgUrl: [],
      newsData: [],
      firstData: null,
      bmData: [],
      qxData: [],
      jbData: [],
      cyData: [],
      nbData: [],
      rsData: [],
      gsData: [],
      linkUrl: [],
      linkImgUrl: [],
      ycywslData: [],
      ycywsyData: [],
      ycywbjData: [],
      sldbData: [],
      qsbj_szlData: [],
      qsbj_jzlData: [],
      regien: [
        { value: 510100, name: "成都市" },
        { value: 510185, name: "简阳市" },
        { value: 510115, name: "温江区" },
        { value: 510104, name: "锦江区" },
        { value: 510105, name: "青羊区" },
        { value: 510106, name: "金牛区" },
        { value: 510107, name: "武侯区" },
        { value: 510108, name: "成华区" },
        { value: 510112, name: "龙泉驿区" },
        { value: 510113, name: "青白江区" },
        { value: 510114, name: "新都区" },
        { value: 510121, name: "金堂县" },
        { value: 510122, name: "双流区" },
        { value: 510124, name: "郫都区" },
        { value: 510129, name: "大邑县" },
        { value: 510132, name: "新津区" },
        { value: 510181, name: "都江堰市" },
        { value: 510182, name: "彭州市" },
        { value: 510131, name: "蒲江县" },
        { value: 510183, name: "邛崃市" },
        { value: 510184, name: "崇州市" },
        { value: 510109, name: "高新区" },
        { value: 510199, name: "天府新区" },
        { value: 510118, name: "东部新区" }
      ],
      image: [
        require("../assets/image/图片 504.png"),
        require("../assets/image/图片 502.png"),
        require("../assets/image/图片 501.png"),
        require("../assets/image/图片 503.png"),
        require("../assets/image/图片 504.png"),
        require("../assets/image/图片 502.png"),
        require("../assets/image/图片 501.png"),
        require("../assets/image/图片 503.png"),
        require("../assets/image/图片 504.png"),
        require("../assets/image/图片 502.png"),
        require("../assets/image/图片 501.png"),
        require("../assets/image/图片 503.png"),
        require("../assets/image/图片 504.png"),
        require("../assets/image/图片 502.png"),
        require("../assets/image/图片 501.png"),
        require("../assets/image/图片 503.png")
      ],
      gjggJzlData: [],
      gjggSzlData: [],
      GcjsLeftData: [],
      GcjsLeftDatTitle: [],
      GcjsLefttotal: null,
      type: "0",
      jsydbpData: {
        blgztj: [],
        bjgz: [],
        cshs: [],
        sbst: [],
        bjzl: []
      },
      sumobj: {},
      WeatherData: [],
      dxywData: [],
      hsycData: [],
      //功能上线列表
      gnsxData: [],
      //功能上线表头数据
      // gnsxTableLabel: [],
      //日期
      dateValue: "2021-7-17 星期六",
      //天气图标
      weatherImg: "阴",
      airValue: "多云 26° ~ 32°",
      username: "",
      userpwd: "",
      bjgzTj: {
        dsl: 0,
        dsh: 0,
        dzj: 0
      },
      yesterday: "",
      beforeMounth: "",
      beforeYear: "",
      YcywslTimer: "",
      YcywblTimer: "",
      sldbTimer: "",
      szlbjTimer: "",
      jzlbjTimer: "",
      fwtjTime: "",
      yddTime: "",
      userInfo: "",
      ycywslDatayear: [],
      ycywslDataday: [],
      ycywslDatamounth: [],
      ycywbjDatayear: [],
      ycywbjDatadate: [],
      ycywbjDatamonth: [],
      qsbjszlDataall: [],
      qsbjszlDatayear: [],
      qsbjszlDatamonth: [],
      qsbjjzlDataall: [],
      qsbjjzlDatayear: [],
      qsbjjzlDatamonth: [],
      sldbDatayear: [],
      sldbDatadate: [],
      sldbDatamonth: [],
      xtdhData: {
        //    mailList:'',  //总数据list
        //分页
        // totalPage: 1, // 统共页数，默认为1
        // currentPage: 1, //当前页数 ，默认为1
        // pageSize: 18, // 每页显示数量
        currentPageData: [], //当前页显示内容
        // page: "1",
        pageSize: 18,
        curPage: 1,
        totalPage: 1
      },
      // 一窗业务--受理
      ycywslDataAll: [],
      //受理登簿
      sldbDataAll: [],
      qsbjszlDataAll: [],
      // 一窗业务--办件
      ycywbjDataAll: [],
      bldData: [],
      //今日受理的数据
      jrslData: {
        newData: "",
        oldData: ""
      },
      // 确权登记 是否折叠
      isQqdhRef: true,
      // 工建改革 是否折叠
      isGjggRef: true,
      // 建设用地报批与监管 是否折叠
      isJsydbpjgRef: true,
      isZhywRef: true,
      // 用户本周办件
      weekFinishDb: "",
      // 公文本周办理
      weekFinishGw: "",
      arr: [],
      newExplan: {},
      zsSumToal: 0,
      isMrValue: true,
      Loading: null,
      zsNames: "",
      processCount: 0,
      jryp: 0,
      bysl: 0,
      cqwbj: 0,
      pjblsj: 0,
      duBan: [],
      gjggdqzbqk: [],
      mhbygjfzJzl: [],
      mhbygjfz: [],
      fwtj: [],
      fzstotal: 0,
      ydd: [],
      gjjscc: 0,
      dbJrsl: null
    };
  },
  created() {
    this.startLoading();
    this.getUserStyle("");
    this.qqdjDataStatic();
    this.getDate();
    this.getUserLinkPowerCount();
    this.getLoginUrLInfo();
    this.getUserLinkPower();
    this.getProcessingData();
    this.finished();
    // 获取本周办件量和公文处理件数
    this.getTodoList();
    this.getPicUrl();
    this.getNews();
    this.getBMData();
    this.getQXData();
    this.getJBData();
    this.getCYData();
    this.getNBData();
    this.getRSData();
    this.getGSData();
    this.getConfigUrlLink();
    this.linkPicSelect();
    this.gjggDataStaticJzl(510100, 2);
    this.gjggDataStaticSzl(510100, 2);
    this.jsydbpDataStatic();
    this.getWeather();
    this.getUserInfo();
    this.getDayHandleCount();
    this.getOverdueInstance();
    this.getConfigSelectData("ZHSW_BYSL");
    this.getConfigSelectData("DB_STATIC_SQL");
    this.getConfigSelectData("GJ_STATIC_SQL");
    this.getConfigSelectData("ZHSW_GJFZ");
    this.getConfigSelectData("ZHSW_GJZSCC");
    this.getBarChartStaticDatafwtj("fwtj");
    this.getConfigSelectData("ZHSW_DBTJ");
    var that = this;
    that.getSlData();
    //受理量
    that.getDJYWSllData();
    setInterval(() => {
      that.getSlData();
      //受理量
      that.getDJYWSllData();
    }, 3000);
  },
  //   beforeUpdate() {

  //   },
  onLoad() {
    let _this = this;
    this.toOrderNum(_this.newNumber); // 这里输入数字即可调用
    this.increaseNumber();
  },
  mounted() {
    setTimeout(() => {
      this.Loading.close();
    }, 3000);
    setTimeout(() => {
      this.Loading.close();
      // this.initAcceptance(this.ycywslDataAll, 3);
      // this.initUseing();
      // this.initHandling(this.qsbjszlDataall, 0);
      // this.initJointTrialCshs();
      this.initJointTrialBjgz();
      this.initZhywFwtj();
    }, 5000);

    //等待2秒后获取，否则document.getElementById为null
    this.imgStartTimer = setTimeout(() => {
      clearTimeout(this.imgStartTimer);
      this.startImgCarousel();
    }, 2000);
    // 隔5s获取待办事项和公文处理待办的数据 重新渲染getSystem
    setInterval(() => {
      // clearInterval(this.timerDb);
      // 自动刷新待办事项
      this.getUserLinkPowerCount();
      // 自动刷新公文处理待办
      this.getProcessingData();
      // 本周办理统计
      this.getTodoList();
    }, 5000);
    //关闭Loading
  },
  destroyed() {
    clearInterval(this.timerDb);
    clearInterval(this.imgCarouselTimer);
  },
  beforeRouteLeave(to, form, next) {
    clearInterval(this.imgCarouselTimer); //离开页面关闭轮播定时器以免下次打开轮播定位混乱
    next();
  },
  methods: {
    //开始加载loading
    startLoading() {
      this.Loading = this.$loading({
        spinner: "", //自定义加载图标类名
        text: "正在加载中...", //显示在加载图标下方的加载文案
        background: this.switchValue
          ? "rgba(0, 0, 0, 0.3)"
          : "rgba(255, 255, 255, 0.9)" //遮罩背景色
      });
    },

    // 定时增长数字
    increaseNumber(count) {
      let self = this;
      // this.timer = setInterval(() => {
      self.newNumber = count;
      this.toOrderNum(self.newNumber); // 这里输入数字即可调用
      self.setNumberTransform();
      // }, 3000);
    },
    getRandomNumber(min, max) {
      return Math.floor(Math.random() * (max - min + 1) + min);
    },
    // 设置文字滚动
    setNumberTransform() {
      const numberItems = this.$refs.numberItem; // 拿到数字的ref，计算元素数量

      const numberArr = this.orderNum.filter(item => !isNaN(item));
      // 结合CSS 对数字字符进行滚动,显示订单数量
      for (let index = 0; index < numberItems.length; index++) {
        const elem = numberItems[index];
        elem.style.transform = `translate(-50%, -${numberArr[index] * 10}%)`;
      }
    },
    // 处理总今日受理数字
    toOrderNum(num) {
      let _this = this;
      num = num.toString();
      // 把订单数变成字符串
      if (num.length < 6) {
        num = "0" + num; // 如未满八位数，添加"0"补位
        _this.toOrderNum(num); // 递归添加"0"补位
      } else if (num.length === 6) {
        // 订单数中加入逗号
        num = num.slice(0, 3) + "," + num.slice(3, 6);
        _this.orderNum = num.split(""); // 将其便变成数据，渲染至滚动数组
      } else {
        // 订单总量数字超过八位显示异常
        _this.$message.warning("订单总量数字过大，显示异常，请联系客服");
      }
    },
    // 工建改革展示
    gjggExplan(name) {
      this.newExplan = {};
      this.bgColor = name;
      this.zsSumToal = 0;
      this.isMrValue = false;
      this.zsNames = name;
      for (let i = 0; i < this.GcjsLeftData.length; i++) {
        if (this.GcjsLeftData[i].name == name) {
          // console.log(this.GcjsLeftData[i]);
          this.newExplan = this.GcjsLeftData[i];
          for (let i = 0; i < this.newExplan.zsSum.length; i++) {
            this.zsSumToal = this.zsSumToal + this.newExplan.zsSum[i].count;
          }
        }
        // else {
        //   this.newExplan.name = name;
        //   this.newExplan.flCoutItems = [];
        // }
      }
    },

    startImgCarousel() {
      var self = this;
      var dom = document.getElementById("imgDivId");
      self.imgWidth = dom.offsetWidth; //图片区域宽度
      self.imgHeigth = dom.offsetHeight; //图片区域高度

      var imgWidth = self.imgWidth / 4 + 2; //展示4张图片，（+2为了不显示最后一张的margin-right）
      var imgsWidth = imgWidth - 9; //每张图片的宽度（减去间隔距离margin-right: 9px）
      var dddDom = document.getElementsByClassName("ddd");
      for (var i = 0, len = dddDom.length; i < len; i++) {
        dddDom[i].style.width = imgsWidth + "px"; //动态赋值图片宽度
      }
      var d120Dom = document.getElementsByClassName("d120");
      for (var i = 0, len = d120Dom.length; i < len; i++) {
        d120Dom[i].style.height = self.imgHeigth + "px"; //动态赋值图片高度
      }
      var dimgDom = document.getElementsByClassName("dimg");
      for (var i = 0, len = dimgDom.length; i < len; i++) {
        dimgDom[i].style.height = self.imgHeigth + "px"; //动态赋值图片高度
      }

      // 定时器，每个3秒移动一次
      self.imgCarouselTimer = setInterval(function() {
        var imgDivWidth = self.imgWidth;
        var imgDivHeight = self.imgHeigth;
        var imgWidth = imgDivWidth / 4 + 2; //展示4张图片，（+2为了不显示最后一张的margin-right）

        // moveLength +=331.5;
        self.moveLength += imgWidth; //移动的宽度
        // if (moveLength<=imgDivWidth){//未移动到尽头(保留功能)
        if (true) {
          //无限循环
          document.getElementById("d12").style =
            "transform:translateX(-" + self.moveLength + "px);";

          //无限循环start
          var imgIndex = self.moveLength / imgWidth - 1; //取得对应图片下标
          var d121Dom = document.getElementsByClassName("d121"); //获取图片dom数组
          var dataDom = d121Dom[imgIndex].innerHTML; //取得对应图片下标的HTML
          dataDom =
            '<div data-v-8dc7cce2 class="d121 d120">' + dataDom + "</div>";
          document.getElementById("d12").innerHTML += dataDom; //加入图片dom数组
          //无限循环end
        } else if (self.moveLength > imgDivWidth) {
          //移动到尽头-->回到第一个
          // moveLength -= 1657.5;
          self.moveLength -= imgWidth * 5;
          document.getElementById("d12").style =
            "transform:translateX(-" + self.moveLength + "px);";
        }
      }, 3000);
    },
    // 获取用户主题
    getUserStyle() {
      this.$.ajax({
        url: this.$API.ajaxPath,
        type: "post",
        data: {
          interfaceName: "antu.newportal-zjx.provider.user.UserProvider",
          methodName: "getUserStyle",
          args: [this.userId]
        },
        dataType: "json",
        success: response => {
          if (response.status == "0") {
            if (response.result == "0") {
              this.switchValue = false;
            } else {
              this.switchValue = true;
            }
          }
        },
        error: xhr => {
          console.log(xhr);
        }
      });
    },
    // 主题切换
    changeUserStyle(style) {
      let param;
      param = [this.userId, style];
      this.$.ajax({
        url: this.$API.ajaxPath,
        type: "post",
        data: {
          interfaceName: "antu.newportal-zjx.provider.user.UserProvider",
          methodName: "changeUserStyle",
          args: param
        },
        dataType: "json",
        success: response => {
          if (response.status == "0") {
          }
        },
        error: xhr => {
          console.log(xhr);
        }
      });
    },
    // 获取昨时间
    getDate() {
      var time = new Date().getTime() - 24 * 60 * 60 * 1000;
      var yesday = new Date(time); // 获取的是前一天日期
      this.yesterday =
        yesday.getFullYear() +
        "年" +
        (yesday.getMonth() > 9
          ? yesday.getMonth() + 1
          : "0" + (yesday.getMonth() + 1)) +
        "月" +
        (yesday.getDate() > 9 ? yesday.getDate() : "0" + yesday.getDate()) +
        "日"; //字符串拼接转格式：例如2018-08-19
      this.beforeMounth =
        yesday.getFullYear() +
        "年" +
        (yesday.getMonth() > 9 ? yesday.getMonth() : "0" + yesday.getMonth()) +
        "月" +
        (yesday.getDate() > 9 ? yesday.getDate() : "0" + yesday.getDate()) +
        "日"; //字符串拼接转格式：例如2018-08-19
      this.beforeYear =
        yesday.getFullYear() -
        1 +
        "年" +
        (yesday.getMonth() > 9 ? yesday.getMonth() : "0" + yesday.getMonth()) +
        "月" +
        (yesday.getDate() > 9 ? yesday.getDate() : "0" + yesday.getDate()) +
        "日"; //字符串拼接转格式：例如2018-08-19
    },
    // 获取登录名和密码
    getLoginUrLInfo() {
      this.$.ajax({
        url: this.$API.ajaxPath,
        type: "post",
        data: {
          interfaceName: this.interfaceName,
          methodName: "getLoginUrLInfo",
          args: [this.userId]
        },
        dataType: "json",
        success: response => {
          if (response.status == "0") {
            response.result = JSON.parse(response.result);
            this.username = response.result.loginName;
            this.userpwd = response.result.pwd;
          }
        },
        error: xhr => {
          console.log(xhr);
        }
      });
    },
    // 上一页
    systemNavigationPrev() {
      if (this.xtdhData.curPage == 1) return;
      this.xtdhData.curPage--;
      this.setCurrentPageData();
      //   if (this.xtdhData.curPage != 1) {
      //     this.xtdhData.page = parseInt(this.xtdhData.page) - 1;

      //     this.getUserLinkPower();
      //   }
    },
    // 下一页
    systemNavigationNext() {
      if (this.xtdhData.curPage == this.xtdhData.totalPage) return;
      this.xtdhData.curPage++;
      this.setCurrentPageData();
      //   if (this.xtdhData.curPage < this.xtdhData.totalPage) {
      //     this.xtdhData.page = parseInt(this.xtdhData.page) + 1;

      //     this.getUserLinkPower();
      //   }
    },

    //分页
    fenye: function() {
      debugger;
      console.log(this.navigatorLink, "eeeeeeeeeeeeeeeeee");
      // 计算一共有几页
      this.xtdhData.totalPage = Math.ceil(
        this.navigatorLink.length / this.xtdhData.pageSize
      );
      console.log("asdsdsdsdsd->" + this.xtdhData.totalPage);
      // 计算得0时设置为1
      this.xtdhData.totalPage =
        this.xtdhData.totalPage == 0 ? 1 : this.xtdhData.totalPage;
      this.setCurrentPageData();
      console.log("总页面数为--->" + this.totalPage);
    },
    // 设置当前页面数据，对数组操作的截取规则为[0~10],[10~20]...,
    setCurrentPageData: function() {
      debugger;
      let begin = (this.xtdhData.curPage - 1) * this.xtdhData.pageSize;
      let end = this.xtdhData.curPage * this.xtdhData.pageSize;
      this.xtdhData.currentPageData = this.navigatorLink.slice(begin, end);
    },

    // 获取用户有权限的系统
    getUserLinkPower() {
      let that = this;
      this.$.ajax({
        url: that.$API.ajaxPath,
        type: "post",
        data: {
          interfaceName: that.interfaceName,
          methodName: "getUserLinkPower",
          args: [that.userId, 1, 200]
        },
        dataType: "json",
        success: response => {
          if (response.status == "0") {
            response.result = JSON.parse(response.result);

            // that.xtdhData.curPage = response.result.currentPage;

            // that.xtdhData.totalPage = response.result.totalPages;

            let tmpResData = [];

            let resData = [];

            let bgColor = {
              事业管理: "sygl-grid",
              行政管理: "xzgl-grid",
              综合事务: "zhsw-grid"
            };

            resData = response.result.items;

            resData.map(item => {
              // item.items.map(child_item => {
              let tmpObj = item;

              tmpObj["lightImg"] = that.$API.iconUrl + item["lightIcon"];

              tmpObj["darkImg"] = that.$API.iconUrl + item["darkIcon"];

              tmpObj["bgColor"] = bgColor[item.type];

              tmpResData.push(tmpObj);
              // });
            });

            tmpResData.sort(function(a, b) {
              return b.clickCount - a.clickCount;
            });

            that.navigatorLink = tmpResData;
            that.fenye();
          }
        },
        error: xhr => {
          console.log(xhr);
        }
      });
    },

    // 获取用户有权限的系统待办数量
    getUserLinkPowerCount() {
      let that = this;
      this.$.ajax({
        url: that.$API.ajaxPath,
        type: "post",
        data: {
          interfaceName: that.interfaceName,
          methodName: "getUserLinkPower",
          args: [that.userId, 1, 200]
        },
        dataType: "json",
        success: response => {
          // console.log("asdasdasdasdasd", response);
          if (response.status == "0") {
            response.result = JSON.parse(response.result);

            that.systemCount = response.result.items.filter(item => {
              return item.count > 0;
            });
            // let tmpResData = [];

            // let resData = [];

            // resData = response.result.items;

            // resData.map(item => {
            //   item.items.map(child_item => {
            //     let tmpObj = child_item;
            //     tmpResData.push(tmpObj);
            //   });
            // });
            // that.systemCount = tmpResData.filter(item => {
            //   return item.count > 0;
            // });

            that.systemCount.forEach((item, index) => {
              item.img = that.image[index];
            });
          }
        },
        error: xhr => {
          console.log(xhr);
        }
      });
    },
    handleSwitch() {
      let style;
      if (this.switchValue) {
        style = 0;
      } else {
        style = 1;
      }
      this.changeUserStyle(style);
      // this.initBanjian(this.ycywbjDataAll, 3);
      this.initregisterdxyw();
      // this.initregisterhsyc();
      this.initJointTrialBjgz();
      this.initJointTrialSbst();
      this.initJointTrialBjzl();
      this.initZhywYdd();
      this.initZhywFwtj();
    },

    initRegister(data, type) {
      if (type == 0) {
        this.sldbTimer = this.yesterday;
      } else if (type == 1) {
        this.sldbTimer = this.beforeMounth + "-" + this.yesterday;
      } else if (type == 2) {
        this.sldbTimer = this.beforeYear + "-" + this.yesterday;
      } else if (type == 3) {
        this.sldbTimer = this.yesterday;
      }
      var chartDom = document.getElementById("register_echart");
      var myChart = echarts.init(chartDom);
      var option;

      option = {
        tooltip: {
          trigger: "axis",
          backgroundColor: this.switchValue
            ? "rgba(255,255,255,0.8)"
            : "rgba(55,55,55,0.8)",
          textStyle: {
            color: this.switchValue ? "#000" : "#fff"
          },
          formatter: function(params) {
            let hintData = params[0].data;

            let returnStr = `<p style="text-align: center;font-size:12px;margin:0;padding:0">${params[0].name}</p>`;

            for (const key in hintData) {
              if (key != "name") {
                returnStr += `<p style="font-size:12px;margin:0;padding:0">${key}: ${hintData[key]}万件</p>`;
              }
            }

            return returnStr;
          }
        },
        grid: {
          top: "50px",
          right: "10px",
          left: "60px",
          bottom: "30px"
        },
        legend: {
          textStyle: {
            color: "rgb(119,121,129)"
          }
        },
        dataset: {
          dimensions: ["name", "受理数", "登簿数"],
          source: data
        },
        xAxis: {
          type: "category",
          axisTick: {
            alignWithLabel: true
          },
          axisLabel: {
            interval: 0
          }
        },
        yAxis: {
          axisLabel: {
            formatter: "{value}万件"
          }
        },
        // Declare several bar series, each will be mapped
        // to a column of dataset.source by default.
        series: [
          {
            type: "bar",
            itemStyle: {
              color: "#386BD3"
            }
          },
          {
            type: "bar",
            itemStyle: {
              color: "#0DC4C2"
            }
          }
        ]
      };
      option && myChart.setOption(option);
    },
    initJointTrialBjgz() {
      var chartDom = document.getElementById("jointTrialBjgz_echart");
      var myChart = echarts.init(chartDom);
      var option;

      option = {
        grid: {
          top: "50px",
          right: "10px",
          left: "50px",
          bottom: "30px"
        },
        legend: {
          textStyle: {
            color: "rgb(119,121,129)"
          }
        },
        tooltip: {
          trigger: "axis",
          backgroundColor: this.switchValue
            ? "rgba(255,255,255,0.8)"
            : "rgba(55,55,55,0.8)",
          textStyle: {
            color: this.switchValue ? "#000" : "#fff"
          },
          formatter: function(params) {
            let hintData = params[0].data;

            let returnStr = `${params[0].name}</br>`;

            for (const key in hintData) {
              if (key != "name") {
                returnStr += `${key}: ${hintData[key]}件</br>`;
              }
            }

            return returnStr;
          }
        },
        dataset: {
          dimensions: ["区县名", "待组卷", "待审核", "待受理"],
          source: this.jsydbpData.bjgz
        },
        xAxis: {
          type: "category",
          axisLabel: {
            interval: 0
          }
        },
        yAxis: {
          axisLabel: {
            formatter: "{value}件"
          }
        },
        // Declare several bar series, each will be mapped
        // to a column of dataset.source by default.
        series: [
          {
            type: "bar",
            itemStyle: {
              color: "#386BD3"
            }
          },
          {
            type: "bar",
            itemStyle: {
              color: "#0DC4C2"
            }
          },
          {
            type: "bar",
            itemStyle: {
              color: "#FAAD14"
            }
          }
        ]
      };

      option && myChart.setOption(option);
    },
    initJointTrialSbst() {
      var chartDom = document.getElementById("jointTrialSbst_echart");
      var myChart = echarts.init(chartDom);
      var option;

      option = {
        grid: {
          top: "50px",
          right: "10px",
          left: "50px",
          bottom: "30px"
        },
        legend: {
          textStyle: {
            color: "rgb(119,121,129)"
          }
        },
        tooltip: {
          trigger: "axis",
          backgroundColor: this.switchValue
            ? "rgba(255,255,255,0.8)"
            : "rgba(55,55,55,0.8)",
          textStyle: {
            color: this.switchValue ? "#000" : "#fff"
          },
          formatter: function(params) {
            let hintData = params[0].data;

            let returnStr = `${params[0].name}</br>`;

            for (const key in hintData) {
              if (key != "NAME") {
                returnStr += `${key}: ${hintData[key]}件</br>`;
              }
            }

            return returnStr;
          }
        },
        dataset: {
          dimensions: [
            "NAME",
            "省厅办结",
            "省厅待受理",
            "省厅待审核",
            "省厅补证",
            "省厅退件"
          ],
          source: this.jsydbpData.sbst
        },
        xAxis: {
          type: "category",
          axisLabel: {
            interval: 0
          }
        },
        yAxis: {
          axisLabel: {
            formatter: "{value}件"
          }
        },
        // Declare several bar series, each will be mapped
        // to a column of dataset.source by default.
        series: [
          {
            type: "bar",
            itemStyle: {
              color: "#0DC4C2"
            }
          },
          {
            type: "bar",
            itemStyle: {
              color: "#386BD3"
            }
          },
          {
            type: "bar",
            itemStyle: {
              color: "#945FB8"
            }
          },
          {
            type: "bar",
            itemStyle: {
              color: "#FAAD14"
            }
          },
          {
            type: "bar",
            itemStyle: {
              color: "#F84848"
            }
          }
        ]
      };

      option && myChart.setOption(option);
    },
    initJointTrialBjzl() {
      var chartDom = document.getElementById("jointTrialBjzl_echart");
      var myChart = echarts.init(chartDom);
      var option;

      option = {
        grid: {
          top: "50px",
          right: "10px",
          left: "50px",
          bottom: "30px"
        },
        legend: {
          textStyle: {
            color: "rgb(119,121,129)"
          }
        },
        tooltip: {
          trigger: "axis",
          backgroundColor: this.switchValue
            ? "rgba(255,255,255,0.8)"
            : "rgba(55,55,55,0.8)",
          textStyle: {
            color: this.switchValue ? "#000" : "#fff"
          },
          formatter: function(params) {
            let hintData = params[0].data;

            let returnStr = `${params[0].name}</br>
            报件数: ${hintData["报件数"]}件</br>
            补正次数: ${hintData["补正次数"]}件·次</br>
            补正件数: ${hintData["补正件数"]}件</br>
            平均补正耗时: ${hintData["平均补正耗时"]}工作日</br>`;

            return returnStr;
          }
        },
        dataset: {
          dimensions: [
            "NAME",
            "报件数",
            "补正次数",
            "补正件数",
            "平均补正耗时"
          ],
          source: this.jsydbpData.bjzl
        },
        xAxis: {
          type: "category",
          axisLabel: {
            interval: 0
          }
        },
        yAxis: {},
        // Declare several bar series, each will be mapped
        // to a column of dataset.source by default.
        series: [
          {
            type: "bar",
            itemStyle: {
              color: "#0DC4C2"
            }
          },
          {
            type: "bar",
            itemStyle: {
              color: "#386BD3"
            }
          },
          {
            type: "bar",
            itemStyle: {
              color: "#945FB8"
            }
          },
          {
            type: "bar",
            itemStyle: {
              color: "#FAAD14"
            }
          }
        ]
      };

      option && myChart.setOption(option);
    },
    // 典型业务
    initregisterdxyw() {
      var chartDom = document.getElementById("registerddxyw_echart");
      var myChart = echarts.init(chartDom);
      var option;
      option = {
        tooltip: {
          trigger: "item",
          backgroundColor: this.switchValue
            ? "rgba(255,255,255,0.8)"
            : "rgba(55,55,55,0.8)",
          textStyle: {
            color: this.switchValue ? "#000" : "#fff"
          },
          formatter: function(params) {
            let hintData = params.data;

            let returnStr = `<p style="text-align: center;font-size:12px;margin:0;padding:0">${hintData.name}</p>`;

            for (const key in hintData) {
              if (key != "name") {
                returnStr += `<p style="font-size:12px;margin:0;padding:0">${key}: ${hintData[key]}小时</p>`;
              }
            }

            return returnStr;
          }
        },
        grid: {
          top: "50px",
          right: "10px",
          left: "50px",
          bottom: "30px"
        },
        legend: {
          textStyle: {
            color: "rgb(119,121,129)"
          }
        },
        dataset: {
          dimensions: [
            "name",
            "二手房买卖散件平均耗时",
            "商品房分户散件平均耗时",
            "商品房分户集体件平均耗时",
            "抵押登记散件平均耗时",
            "抵押登记集体件平均耗时"
          ],
          source: this.dxywData
        },
        xAxis: {
          type: "category",
          axisTick: {
            alignWithLabel: true
          },
          axisLabel: {
            interval: 0
          }
        },
        yAxis: {
          axisLabel: {
            formatter: "{value}小时"
          }
        },
        // Declare several bar series, each will be mapped
        // to a column of dataset.source by default.
        series: [
          {
            type: "bar",
            itemStyle: {
              color: "#0DC4C2"
            }
          },
          {
            type: "bar",
            itemStyle: {
              color: "#386BD3"
            }
          },
          {
            type: "bar",
            itemStyle: {
              color: "#945FB8"
            }
          },
          {
            type: "bar",
            itemStyle: {
              color: "#FAAD14"
            }
          },
          {
            type: "bar",
            itemStyle: {
              color: "#F84848"
            }
          }
        ]
      };

      option && myChart.setOption(option);
    },

    initZhywFwtj() {
      var chartDom = document.getElementById("statisticsfwtj_echart");
      var myChart = echarts.init(chartDom);
      var option;
      var dataX = [],
        datay = [];
      this.fwtj.forEach(item => {
        dataX.push(item.name);
        datay.push(item["件"]);
      });
      option = {
        grid: {
          top: "50px",
          right: "10px",
          left: "50px",
          bottom: "60px"
        },
        tooltip: {
          trigger: "axis",
          backgroundColor: this.switchValue
            ? "rgba(255,255,255,0.8)"
            : "rgba(55,55,55,0.8)",
          textStyle: {
            color: this.switchValue ? "#000" : "#fff"
          },
          formatter: function(params) {
            let hintData = params[0];

            let returnStr = `${hintData.name}</br>
            ${hintData.data}件`;

            return returnStr;
          }
        },
        xAxis: {
          type: "category",
          boundaryGap: true,
          data: dataX,
          axisLabel: {
            interval: 0,
            rotate: 45
          },
          axisTick: {
            alignWithLabel: true //类目轴中在 boundaryGap 为 true 的时候有效，
            //可以保证刻度线和标签对齐,不设置会出现柱状图不在刻度线中间
          }
        },
        // xAxis: {
        //   type: "category",
        //   data: dataX
        // },
        yAxis: {
          type: "value",
          axisLabel: {
            formatter: "{value}件"
          }
        },
        series: [
          {
            data: datay,
            type: "bar"
          }
        ]
      };

      option && myChart.setOption(option);
    },

    initZhywYdd() {
      var chartDom = document.getElementById("statisticsydd_echart");
      var myChart = echarts.init(chartDom);
      var option;
      var dataX = [],
        datay = [];
      this.ydd.forEach(item => {
        dataX.push(item.name);
        datay.push(item["办件量"]);
      });
      option = {
        grid: {
          top: "50px",
          right: "10px",
          left: "80px",
          bottom: "60px"
        },
        tooltip: {
          trigger: "axis",
          backgroundColor: this.switchValue
            ? "rgba(255,255,255,0.8)"
            : "rgba(55,55,55,0.8)",
          textStyle: {
            color: this.switchValue ? "#000" : "#fff"
          },
          formatter: function(params) {
            let hintData = params[0];

            let returnStr = `${hintData.name}</br>
            ${hintData.data}件`;

            return returnStr;
          }
        },
        xAxis: {
          type: "category",
          boundaryGap: true,
          data: dataX,
          axisLabel: {
            interval: 0,
            rotate: 45
          },
          axisTick: {
            alignWithLabel: true //类目轴中在 boundaryGap 为 true 的时候有效，
            //可以保证刻度线和标签对齐,不设置会出现柱状图不在刻度线中间
          }
        },

        yAxis: {
          type: "value",
          axisLabel: {
            formatter: "{value}件"
          }
        },
        series: [
          {
            data: datay,
            type: "bar"
          }
        ]
      };

      option && myChart.setOption(option);
    },
    getProcessingData() {
      this.$.ajax({
        url: this.$API.ajaxPath,
        type: "post",
        data: {
          interfaceName: this.interfaceName,
          methodName: "gwHandle",
          args: [this.userId]
        },
        dataType: "json",
        success: response => {
          if (response.status == "0") {
            response.result = JSON.parse(response.result);
            let data = [];
            response.result.items.forEach((element, index) => {
              if (index < 4) {
                data.push(element);
              }
            });
            this.processData = data;
            if (this.processData.length == 0 && this.processCount == 0) {
              this.processShow = false;
            }
            // if (this.processData.length != 0 && this.processCount == 0) {
            //   this.processShow = true;
            // }
            this.processCount += 1;
          }
        },
        error: xhr => {
          console.log(xhr);
        }
      });
    },
    clickdb() {
      this.getProcessingData();
      this.processShow = true;
    },
    finishedClick() {
      this.processShow = false;
      this.finished();
    },
    finished() {
      this.$.ajax({
        url: this.$API.ajaxPath,
        type: "post",
        data: {
          interfaceName: this.interfaceName,
          methodName: "gwLatelyOver",
          args: [this.userId]
        },
        dataType: "json",
        success: response => {
          if (response.status == "0") {
            response.result = JSON.parse(response.result);
            let data = [];
            response.result.forEach((element, index) => {
              if (index < 4) {
                data.push(element);
              }
            });
            this.finishedData = data;
            // console.log(response.result);
          }
        },
        error: xhr => {
          console.log(xhr);
        }
      });
    },
    // 待办事项
    getTodoList() {
      let param = [this.userId, "公文本周办理,用户本周办件"];
      let that = this;
      this.$.ajax({
        url: this.$API.ajaxPath,
        type: "post",
        data: {
          interfaceName: this.interfaceName,
          methodName: "systemHandle",
          args: param
        },
        dataType: "json",
        success: response => {
          if (response.status == "0") {
            let weeekRes = JSON.parse(response.result);
            for (let i = 0; i < weeekRes.length; i++) {
              if (weeekRes[i].name == "用户本周办件") {
                that.weekFinishDb = weeekRes[i].count;
              } else if (weeekRes[i].name == "公文本周办理") {
                that.weekFinishGw = weeekRes[i].count;
              }
            }
          }
        },
        error: xhr => {
          console.log(xhr);
        }
      });
    },
    // 获取要闻推荐图片
    getPicUrl() {
      this.$.ajax({
        url: this.$API.ajaxPath,
        type: "post",
        data: {
          interfaceName: this.interfaceName,
          methodName: "getNewPic",
          args: [this.userId]
        },
        dataType: "json",
        success: response => {
          if (response.status == "0") {
            this.imgUrl = JSON.parse(response.result);
          }
        },
        error: xhr => {
          console.log(xhr);
        }
      });
    },

    handleClickNew(tab, event) {
      let param = null;
      if (tab.index == 1) {
      }
      if (tab.index == 2) {
      }
    },

    // 要闻推荐
    getNews() {
      let data = [this.userId, 1];
      this.$.ajax({
        url: this.$API.ajaxPath,
        type: "post",
        data: {
          interfaceName: this.interfaceName,
          methodName: "getNews",
          args: data
        },
        dataType: "json",
        success: response => {
          if (response.status == "0") {
            response.result = JSON.parse(response.result);
            this.firstData = response.result[0];
            response.result.forEach((element, index) => {
              if (index < 5 && index != 0) {
                this.newsData.push(element);
              }
            });
          }
        },
        error: xhr => {
          console.log(xhr);
        }
      });
    },
    // 获取部门动态数
    getBMData() {
      let data = [this.userId, 9];
      this.$.ajax({
        url: this.$API.ajaxPath,
        type: "post",
        data: {
          interfaceName: this.interfaceName,
          methodName: "getNews",
          args: data
        },
        dataType: "json",
        success: response => {
          if (response.status == "0") {
            response.result = JSON.parse(response.result);
            response.result.forEach((element, index) => {
              if (index < 8) {
                this.bmData.push(element);
              }
            });
          }
        },
        error: xhr => {
          console.log(xhr);
        }
      });
    },
    // 获取区县数据
    getQXData() {
      let data = [this.userId, 2];
      this.$.ajax({
        url: this.$API.ajaxPath,
        type: "post",
        data: {
          interfaceName: this.interfaceName,
          methodName: "getNews",
          args: data
        },
        dataType: "json",
        success: response => {
          if (response.status == "0") {
            response.result = JSON.parse(response.result);
            response.result.forEach((element, index) => {
              if (index < 8) {
                this.qxData.push(element);
              }
            });
          }
        },
        error: xhr => {
          console.log(xhr);
        }
      });
    },
    // 获取区县数据
    getJBData() {
      let data = [this.userId, 4, 5];
      this.$.ajax({
        url: this.$API.ajaxPath,
        type: "post",
        data: {
          interfaceName: this.interfaceName,
          methodName: "getNews",
          args: data
        },
        dataType: "json",
        success: response => {
          if (response.status == "0") {
            response.result = JSON.parse(response.result);
            response.result.forEach((element, index) => {
              if (index < 8) {
                this.jbData.push(element);
              }
            });
          }
        },
        error: xhr => {
          console.log(xhr);
        }
      });
    },
    // 获取参阅信息
    getCYData() {
      let data = [this.userId];
      this.$.ajax({
        url: this.$API.ajaxPath,
        type: "post",
        data: {
          interfaceName: this.interfaceName,
          methodName: "getReferencInfo",
          args: data
        },
        dataType: "json",
        success: response => {
          if (response.status == "0") {
            response.result = JSON.parse(response.result);
            response.result.forEach((element, index) => {
              if (index < 8) {
                this.cyData.push(element);
              }
            });
          }
        },
        error: xhr => {
          console.log(xhr);
        }
      });
    },
    // 内部公示
    getNBData() {
      let data = [this.userId];
      this.$.ajax({
        url: this.$API.ajaxPath,
        type: "post",
        data: {
          interfaceName: this.interfaceName,
          methodName: "getInsideAnnouncement",
          args: data
        },
        dataType: "json",
        success: response => {
          if (response.status == "0") {
            response.result = JSON.parse(response.result);
            response.result.forEach((element, index) => {
              if (index < 8) {
                this.nbData.push(element);
              }
            });
          }
        },
        error: xhr => {
          console.log(xhr);
        }
      });
    },
    // 人事任免
    getRSData() {
      let data = [this.userId, 4, 5];
      this.$.ajax({
        url: this.$API.ajaxPath,
        type: "post",
        data: {
          interfaceName: this.interfaceName,
          methodName: "getEmployChange",
          args: data
        },
        dataType: "json",
        success: response => {
          if (response.status == "0") {
            response.result = JSON.parse(response.result);
            response.result.forEach((element, index) => {
              if (index < 8) {
                this.rsData.push(element);
              }
            });
          }
        },
        error: xhr => {
          console.log(xhr);
        }
      });
    },
    // 公示公告
    getGSData() {
      let data = [this.userId, 7];
      this.$.ajax({
        url: this.$API.ajaxPath,
        type: "post",
        data: {
          interfaceName: this.interfaceName,
          methodName: "getNews",
          args: data
        },
        dataType: "json",
        success: response => {
          if (response.status == "0") {
            response.result = JSON.parse(response.result);
            response.result.forEach((element, index) => {
              if (index < 8) {
                this.gsData.push(element);
              }
            });
          }
        },
        error: xhr => {
          console.log(xhr);
        }
      });
    },

    // 获取链接信息
    getConfigUrlLink() {
      this.$.ajax({
        url: this.$API.ajaxPath,
        type: "post",
        data: {
          interfaceName: this.interfaceName,
          methodName: "getConfigUrlLink",
          args: [this.userId]
        },
        dataType: "json",
        success: response => {
          if (response.status == "0") {
            this.linkUrl = JSON.parse(response.result);
          }
        },
        error: xhr => {
          console.log(xhr);
        }
      });
    },
    xtdhClick(link, sysId) {
      this.clickRecord(sysId);
      this.getSystemInfo(sysId);
    },
    clickRecord(linkId) {
      this.$.ajax({
        url: this.$API.ajaxPath,
        type: "post",
        data: {
          interfaceName: this.interfaceName,
          methodName: "clickRecord",
          args: [this.userId, linkId]
        },
        dataType: "json",
        success: response => {
          if (response.status == "0") {
            console.log(response.message);
          }
        },
        error: xhr => {
          console.log(xhr);
        }
      });
    },
    getSystemInfo(sysId) {
      this.$.ajax({
        url: this.$API.ajaxPath,
        type: "post",
        data: {
          interfaceName: this.interfaceName,
          methodName: "getSystemInfo",
          args: [sysId, this.userId]
        },
        dataType: "json",
        success: response => {
          if (response.status == "0") {
            response.result = JSON.parse(response.result);
            this.userList = response.result.userList;
            this.switchHandle(
              response.result.errorlink,
              response.result.state.toString(),
              response.result.userList,
              sysId
            );
          }
        },
        error: xhr => {
          console.log(xhr);
        }
      });
    },
    switchHandle(_errorlink, _state, userList, sysId) {
      switch (_state) {
        case "0":
          if (_errorlink != null && _errorlink != "") {
            if (_errorlink.indexOf("http") == -1) {
              alert(_errorlink);
            } else {
              window.open(_errorlink);
            }
          }
          break;
        case "1":
          alert("你无查看目标系统权限，请和管理员联系！");
          break;
        case "2":
          this.GetSystemUrl(_state, sysId);
          break;
        case "3":
          if (this.userList.length > 1) {
            this.dialogFormVisible = true;
            this.state = _state;
            this.sysId = sysId;
          } else {
            this.GetSystemUrl(_state, sysId);
          }

          // this.GetSystemUrl(_state, sysId);
          break;
        case "4":
          if (this.userList.length > 1) {
            this.dialogFormVisible = true;
            this.state = _state;
            this.sysId = sysId;
          } else {
            this.GetSystemUrl(_state, sysId);
          }
          // this.GetSystemUrl(_state, sysId);
          break;
      }
    },
    GetSystemUrl(state, sysId) {
      let param;
      if (state == "2" || state == "3" || state == "4") {
        param = [sysId, this.userId];
      } else if (this.state == "3") {
        param = [this.roleID, this.sysId];
      } else if (this.state == "4") {
        param = [this.roleID, this.sysId];
      }
      this.$.ajax({
        url: this.$API.ajaxPath,
        type: "post",
        data: {
          interfaceName: this.interfaceName,
          methodName: "getSystemUrl",
          args: param
        },
        dataType: "json",
        success: response => {
          if (response.status == "0") {
            // response.result = JSON.parse(response.result);
            // unescape(_OpenUrl);
            this.dialogFormVisible = false;
            this.roleID = "";
            window.open(unescape(response.result));
          }
        },
        error: xhr => {
          console.log(xhr);
        }
      });
    },
    handleClickblhs(name) {
      this.linkUrl.forEach(item => {
        if (item.name == name) {
          window.open(item.url);
        }
      });
    },
    handleLink(name) {
      this.linkUrl.forEach(item => {
        if (item.name == name) {
          if (item.url.indexOf("?") != -1) {
            window.open(
              item.url + "&uid=" + this.username + "&pwd=" + this.userpwd
            );
          } else {
            window.open(
              item.url + "?uid=" + this.username + "&pwd=" + this.userpwd
            );
          }
        }
      });
    },
    finishedLink(name, step, IID, WIID, WNAME) {
      this.linkUrl.forEach(item => {
        if (item.name == name) {
          if (item.url.indexOf("?") != -1) {
            window.open(
              item.url +
                "&uid=" +
                this.username +
                "&pwd=" +
                this.userpwd +
                "&iid=" +
                IID +
                "&wiid=" +
                WIID +
                "&jump=1&step=" +
                encodeURI(step) +
                "&check=true" +
                "&WNAME=" +
                WNAME
            );
          } else {
            window.open(
              item.url +
                "?uid=" +
                this.username +
                "&pwd=" +
                this.userpwd +
                "&iid=" +
                IID +
                "&wiid=" +
                WIID +
                "&jump=1&step=" +
                encodeURI(step) +
                "&check=true"
            );
          }
        }
      });
    },
    newsLink(mid) {
      this.$router.push({
        path: "/newsCenter",
        query: {
          mid: mid
        }
      });
    },
    detailClickLink(mid, nid) {
      this.$router.push({
        path: "/newsCenter",
        query: {
          mid: mid,
          nid: nid
        }
      });
    },
    // 待办和最近已完成详情跳转链接
    detailLink(name, step, IID, WIID, WNAME) {
      this.linkUrl.forEach(item => {
        if (item.name == name && item.needAccountInfo == true) {
          window.open(
            item.url +
              "?uid=" +
              this.username +
              "&pwd=" +
              this.userpwd +
              "&iid=" +
              IID +
              "&wiid=" +
              WIID +
              "&jump=1&step=" +
              encodeURI(step) +
              "&WNAME=" +
              WNAME
          );
        }
      });
    },
    gsggLink(name, id) {
      this.linkUrl.forEach(item => {
        if (item.name == name) {
          window.open(
            item.url +
              "&id=" +
              id +
              "&uid=" +
              this.username +
              "&pwd=" +
              this.userpwd
          );
        }
      });
    },
    rsrmLink(name, id) {
      this.linkUrl.forEach(item => {
        if (item.name == name) {
          window.open(item.url + "?id=" + id);
        }
      });
    },
    cyxxClick(title, IID, WIID) {
      window.open(
        "http://172.18.2.232:8888/portal/page/cdindex.html?page=tyck&uid=" +
          this.username +
          "&pwd=" +
          this.userpwd +
          "&ptiid=" +
          IID +
          "&ptwiid=" +
          WIID +
          "&ptname=" +
          title
      );
    },
    jbxxClick(id) {
      this.$.ajax({
        url: this.$API.ajaxPath,
        type: "post",
        data: {
          interfaceName: this.interfaceName,
          methodName: "getFileById",
          args: [id]
        },
        dataType: "json",
        success: response => {
          if (response.status == "0") {
            if (response.result.indexOf(".pdf") != -1) {
              window.open(response.result);
            }
          }
        },
        error: xhr => {
          console.log(xhr);
        }
      });
    },
    nbgsClick(id) {
      this.$.ajax({
        url: this.$API.ajaxPath,
        type: "post",
        data: {
          interfaceName: this.interfaceName,
          methodName: "getnbgsLink",
          args: [id, this.userId]
        },
        dataType: "json",
        success: response => {
          if (response.status == "0") {
            window.open(response.result);
          }
        },
        error: xhr => {
          console.log(xhr);
        }
      });
    },
    // 待办和最近已完成跳转链接
    // 获取图片链接
    linkPicSelect() {
      this.$.ajax({
        url: this.$API.ajaxPath,
        type: "post",
        data: {
          interfaceName: this.interfaceName,
          methodName: "linkPicSelect",
          args: [this.userId]
        },
        dataType: "json",
        success: response => {
          if (response.status == "0") {
            this.linkImgUrl = JSON.parse(response.result);
          }
        },
        error: xhr => {
          console.log(xhr);
        }
      });
    },
    handleImgLink(url) {
      window.open(url);
    },

    getPercentageData(data) {
      let res = [];
      //先分类汇总
      let sumobj = {};
      let keyArr = [];
      let total = 0;
      for (let i = 0; i < data.length; i++) {
        let key = data[i].name;
        let value = parseInt(data[i].num);
        if (Object.keys(sumobj).indexOf(key) < 0) {
          keyArr.push(key);
          sumobj[key] = value;
        } else {
          sumobj[key] += value;
        }
        total += value;
      }
      this.sumobj = sumobj;
      // console.log(sumobj);
      //然后算
      for (let key of keyArr) {
        res.push({
          name: key,
          value: Math.round((sumobj[key] / total) * 10000) / 100
        });
      }
      return res;
    },
    getYcData(data) {
      let res = [];
      var that = this;

      res = data.filter(item => {
        return item.serial == "";
      });

      res.map(item => {
        item["value"] = item.num;
      });

      return res;
    },

    qqdjDataStatic() {
      this.$.ajax({
        url: this.$API.ajaxPath,
        type: "post",
        data: {
          interfaceName: this.interfaceName,
          methodName: "qqdjDataStatic",
          args: [this.userId]
        },
        dataType: "json",
        success: response => {
          if (response.status == "0") {
            response.result = JSON.parse(response.result);
            this.ycywsyData = response.result["“一窗平台”使用情况"];

            //取出一窗数据
            this.ycywslDataAll = this.getYcData(
              response.result["一窗业务受理-默认"]
            );

            this.ycywslDatayear = this.getPercentageData(
              response.result["一窗业务受理-年"]
            );
            this.ycywslDataday = this.getPercentageData(
              response.result["一窗业务受理-日"]
            );
            this.ycywslDatamounth = this.getPercentageData(
              response.result["一窗业务受理-月"]
            );

            this.ycywbjDataAll = response.result["一窗办件-默认"];
            this.ycywbjDatayear = response.result["一窗办件-年"];
            this.ycywbjDatadate = response.result["一窗办件-日"];
            this.ycywbjDatamonth = response.result["一窗办件-月"];

            this.qsbjszlDataall =
              response.result["全市办件量统计（市政类）-全"];
            this.qsbjszlDatayear =
              response.result["全市办件量统计（市政类）-年"];
            this.qsbjszlDatamonth =
              response.result["全市办件量统计（市政类）-月"];
            this.qsbjjzlDataall =
              response.result["全市办件量统计（建筑类）-全"];
            this.qsbjjzlDatayear =
              response.result["全市办件量统计（建筑类）-年"];
            this.qsbjjzlDatamonth =
              response.result["全市办件量统计（建筑类）-月"];
            this.dxywData = response.result["典型业务"];
            this.gnsxData = response.result["功能上线"];

            // for (let key in this.gnsxData[0]) {
            //   let tmpLabel = {
            //     label: key,
            //     prop: key,
            //     width: "100"
            //   };
            //   this.gnsxTableLabel.push(tmpLabel);
            // }
            // this.$nextTick(() => {
            //   this.$refs.gnsxDataTable.doLayout();
            // });

            this.sldbDataAll = response.result["受理登簿-默认"];

            this.sldbDatayear = response.result["受理登簿-年"];
            this.sldbDatadate = response.result["受理登簿-日"];
            this.sldbDatamonth = response.result["受理登簿-月"];
            // this.hsycData = response.result["耗时异常"];
            let tmpResData = response.result["耗时异常"];
            tmpResData.sort(function(a, b) {
              return b["在办积压"] - a["在办积压"];
            });
            this.hsycData = tmpResData;
          }
        },
        error: xhr => {
          console.log(xhr);
        }
      });
    },

    select() {
      this.gjggDataStaticJzl(this.formInline.region, this.formInline.time);
      this.gjggDataStaticSzl(this.formInline.region, this.formInline.time);
    },
    // 工建改革 统计数据查询 建筑类
    gjggDataStaticJzl(code, date) {
      this.$.ajax({
        url: this.$API.ajaxPath,
        type: "post",
        data: {
          interfaceName: this.interfaceName,
          methodName: "gjggDataStatic",
          args: [0, code, date]
        },
        dataType: "json",
        success: response => {
          if (response.status == "0") {
            this.gjggJzlData = JSON.parse(response.result);
          }
        },
        error: xhr => {
          console.log(xhr);
        }
      });
    },
    // 市政类
    gjggDataStaticSzl(code, date) {
      this.$.ajax({
        url: this.$API.ajaxPath,
        type: "post",
        data: {
          interfaceName: this.interfaceName,
          methodName: "gjggDataStatic",
          args: [1, code, date]
        },
        dataType: "json",
        success: response => {
          if (response.status == "0") {
            this.gjggSzlData = JSON.parse(response.result);
          }
        },
        error: xhr => {
          console.log(xhr);
        }
      });
    },
    //  工建改革左侧数据

    // 工建改革跳转
    gjggLink() {
      window.open(
        "http://172.18.2.207:8080/webroot/decision/view/report?viewlet=gj3scjd%252Fjzydtj.cpt&op=view&tjsj=%E6%9C%88&regionname=ALL"
      );
    },
    jsydClick(tab) {
      if (tab.index == 0) {
        setTimeout(() => {
          this.initJointTrialBjgz();
        }, 100);
      }
      if (tab.index == 1) {
        setTimeout(() => {
          this.initJointTrialSbst();
        }, 100);
      }
      if (tab.index == 2) {
        setTimeout(() => {
          this.initJointTrialBjzl();
        }, 100);
      }
    },
    // 建设用地报批与监管
    jsydbpDataStatic() {
      this.$.ajax({
        url: this.$API.ajaxPath,
        type: "post",
        data: {
          interfaceName: this.interfaceName,
          methodName: "jsydbpDataStatic",
          args: [this.userId]
        },
        dataType: "json",
        success: response => {
          if (response.status == "0") {
            response.result = JSON.parse(response.result);
            this.jsydbpData.blgztj = JSON.parse(
              response.result["办理跟踪统计"]
            );
            this.jsydbpData.bjgz = JSON.parse(response.result["报件跟踪统计"]);
            let tmpResData = JSON.parse(response.result["处室会审统计"]);
            tmpResData.sort(function(a, b) {
              return b["会审数"] - a["会审数"];
            });
            this.jsydbpData.cshs = tmpResData;

            this.jsydbpData.sbst = JSON.parse(response.result["上报省厅统计"]);
            this.jsydbpData.bjzl = JSON.parse(response.result["报件质量统计"]);
            // this.response.result.forEach(item => {});
          }
        },
        error: xhr => {
          console.log(xhr);
        }
      });
    },
    // 天气
    getWeather() {
      var that = this;
      this.$.ajax({
        url: this.$API.ajaxPath,
        type: "post",
        data: {
          interfaceName: this.interfaceName,
          methodName: "getWeather",
          args: [this.userId]
        },
        dataType: "json",
        success: response => {
          if (response.status == "0") {
            // console.log("天气数据", JSON.parse(response.result));
            var WeatherData = JSON.parse(response.result);

            //日期
            that.dateValue =
              WeatherData.date.split("-")[0] +
              "年" +
              WeatherData.date.split("-")[1] +
              "月" +
              WeatherData.date.split("-")[2] +
              "日" +
              " " +
              that.weekDayTransform();
            //天气图标
            that.weatherImg = WeatherData.dayweather;
            that.airValue =
              WeatherData.dayweather +
              " " +
              WeatherData.nighttemp +
              "℃~" +
              WeatherData.daytemp +
              "℃";
          }
        },
        error: xhr => {
          console.log(xhr);
        }
      });
    },
    // 星期
    weekDayTransform() {
      var dayWeek = "";

      var weekVal = new Date().getDay();

      switch (weekVal) {
        case 0:
          dayWeek = "星期日";

          break;

        case 1:
          dayWeek = "星期一";

          break;

        case 2:
          dayWeek = "星期二";

          break;

        case 3:
          dayWeek = "星期三";

          break;

        case 4:
          dayWeek = "星期四";

          break;

        case 5:
          dayWeek = "星期五";

          break;

        case 6:
          dayWeek = "星期六";

          break;

        default:
          break;
      }

      return dayWeek;
    },
    // tab切换
    registerClick(tab) {
      if (tab.index == 1) {
        setTimeout(() => {
          this.initregisterdxyw();
        }, 200);
      }
      if (tab.index == 2) {
        setTimeout(() => {
          this.initRegister(this.sldbDataAll, 3);
        }, 200);
      }
    },
    search() {
      window.open(
        "http://172.18.2.38:8099/qwjs/#/?uid=" +
          this.username +
          "&pwd=" +
          this.userpwd +
          "&text=" +
          this.searchValue +
          "&jump=3" +
          "&classify=" +
          this.bgc
      );
    },
    logout() {
      localStorage.removeItem("USER_ID");
      localStorage.removeItem("TOKEN");
      this.$router.push("/");
    },
    getUserInfo() {
      var that = this;
      this.$.ajax({
        url: this.$API.ajaxPath,
        type: "post",
        data: {
          interfaceName: "antu.newportal-zjx.provider.user.UserProvider",
          methodName: "getUserInfo",
          args: [localStorage.getItem("USER_ID")]
        },
        dataType: "json",
        success: response => {
          if (response.status == "0") {
            response.result = JSON.parse(response.result);
            that.userInfo = response.result;
          }
        },
        error: xhr => {
          console.log(xhr);
        }
      });
    },
    // 返回顶部
    gotoTop() {
      document.documentElement.scrollTop = document.body.scrollTop = 0;
    },
    // 获取办理点
    getSlData() {
      var that = this;
      this.$.ajax({
        url: this.$API.ajaxPath,
        type: "post",
        data: {
          interfaceName: this.interfaceName,
          methodName: "bdcBldxx",
          args: [localStorage.getItem("USER_ID")]
        },
        dataType: "json",
        success: response => {
          if (response.status == "0") {
            response.result = JSON.parse(response.result);
            that.bldData = response.result;
          }
        },
        error: xhr => {
          console.log(xhr);
        }
      });
    },
    // 获取确权登记-今日受理信息
    getDJYWSllData() {
      var that = this;
      this.$.ajax({
        url: this.$API.ajaxPath,
        type: "post",
        data: {
          interfaceName: this.interfaceName,
          methodName: "bdcYwdjSl",
          args: [localStorage.getItem("USER_ID")]
        },
        dataType: "json",
        success: response => {
          if (response.status == "0") {
            response.result = JSON.parse(response.result);
            that.jrslData.newData = response.result;
            that.jrslData.newData["总受理数"] = that.jrslData.newData[
              "总受理数"
            ].toString();
            this.increaseNumber(that.jrslData.newData["总受理数"]);
          }
        },
        error: xhr => {
          console.log(xhr);
        }
      });
    },
    // 获取搜索关键词
    getAllClassify() {
      var _this = this;
      //注意：从本地录取的文件dl和lx相等。
      let params = [];
      params.push(_this.$.cookie("token"));
      this.$.ajax({
        url: "http://172.18.2.38:10985/callProvider",
        type: "post",
        data: {
          interfaceName: "antu.elasticsearch.provider.search",
          methodName: "getAllClassify",
          args: params
        },
        dataType: "json",
        success: response => {
          if (response.status == "0") {
            _this.TabLists = JSON.parse(response.result);
          } else {
            _this.link =
              "http://172.18.4.30:31135/onemapV5.0/pages/otherIframe/jsydsp_custom_overlay.html";
            _this.$message.error(response.message);
          }
        },
        error: xhr => {
          _this.link =
            "http://172.18.4.30:31135/onemapV5.0/pages/otherIframe/jsydsp_custom_overlay.html";
          _this.$message.error(xhr.status + ":" + xhr.statusText);
        }
      });
    },
    // 展开与折叠统计图表
    opCloChart(type) {
      if (type == "qqdhRef") {
        this.isQqdhRef = !this.isQqdhRef;
      } else if (type == "gjggRef") {
        this.isGjggRef = !this.isGjggRef;
      } else if (type == "jsydbpjgRef") {
        this.isJsydbpjgRef = !this.isJsydbpjgRef;
      } else if (type == "zhyw") {
        this.isZhywRef = !this.isZhywRef;
      }
    },

    // 今日批阅
    getDayHandleCount() {
      this.$.ajax({
        url: this.$API.ajaxPath,
        type: "post",
        data: {
          interfaceName:
            "antu.newportal-zjx.provider.synthesisbusiness.SynthesisBusiness",
          methodName: "getDayHandleCount",
          args: [this.userId]
        },
        dataType: "json",
        success: response => {
          if (response.status == "0") {
            this.jryp = JSON.parse(response.result);
          }
        },
        error: xhr => {
          console.log(xhr);
        }
      });
    },
    // 超期未办理
    getOverdueInstance() {
      this.$.ajax({
        url: this.$API.ajaxPath,
        type: "post",
        data: {
          interfaceName:
            "antu.newportal-zjx.provider.synthesisbusiness.SynthesisBusiness",
          methodName: "getOverdueInstance",
          args: [this.userId]
        },
        dataType: "json",
        success: response => {
          if (response.status == "0") {
            response.result = JSON.parse(response.result);
            this.cqwbj = response.result[0].COUNT;
          }
        },
        error: xhr => {
          console.log(xhr);
        }
      });
    },

    // 本月受理
    getConfigSelectData(type) {
      this.$.ajax({
        url: this.$API.ajaxPath,
        type: "post",
        data: {
          interfaceName: this.interfaceName,
          methodName: "getConfigSelectData",
          args: [type, ""]
        },
        dataType: "json",
        success: response => {
          if (response.status == "0") {
            response.result = JSON.parse(response.result);
            if (type == "ZHSW_BYSL") {
              this.bysl = response.result[0].COUNT;
            }
            if (type == "DB_STATIC_SQL") {
              this.duBan = response.result;
            }
            if (type == "GJ_STATIC_SQL") {
              response.result.filter(item => {
                if (item.STATUS == 1) {
                  this.gjggdqzbqk.push(item);
                }
                if (item.STATUS == 2) {
                  this.pjblsj = (item["办理时间"] / item["办理数"]).toFixed(1);
                }
              });
            }
            if (type == "ZHSW_GJFZ") {
              this.mhbygjfz = response.result.filter(item => {
                return item.TYPE != "建筑类";
              });
              response.result.forEach(item => {
                if (item.TYPE == "建筑类") {
                  this.mhbygjfzJzl.push(item);
                }
                this.fzstotal += item.COUNT;
              });
            }
            if (type == "ZHSW_GJZSCC") {
              this.gjjscc = response.result;
            }
            // 督办
            if (type == "ZHSW_DBTJ") {
              let tmpData = response.result;
              let that = this;
              this.dbJrsl = {};
              if (tmpData.length < 0) {
                tmpData.map(item => {
                  that.dbJrsl[item.NAME] = item.COUNT;
                });
              }
            }
          }
        },
        error: xhr => {
          console.log(xhr);
        }
      });
    },
    // 获取综合业务无柱状图数据 发文统计
    getBarChartStaticDatafwtj(type) {
      if (type == "fwtj") {
        this.fwtjTime = this.yesterday;
      } else if (type == "fwtj_month") {
        this.fwtjTime = this.beforeMounth + "-" + this.yesterday;
      } else if (type == "fwtj_year") {
        this.fwtjTime = this.beforeYear + "-" + this.yesterday;
      }
      this.$.ajax({
        url: this.$API.ajaxPath,
        type: "post",
        data: {
          interfaceName: this.interfaceName,
          methodName: "getBarChartStaticData",
          args: [type]
        },
        dataType: "json",
        success: response => {
          if (response.status == "0") {
            this.fwtj = JSON.parse(response.result);
            setTimeout(() => {
              this.initZhywFwtj();
            }, 100);
          }
        },
        error: xhr => {
          console.log(xhr);
        }
      });
    },

    getBarChartStaticDataydd(type) {
      if (type == "mobileSystem") {
        this.yddTime = this.yesterday;
      } else if (type == "mobileSystem_month") {
        this.yddTime = this.beforeMounth + "-" + this.yesterday;
      } else if (type == "mobileSystem_year") {
        this.yddTime = this.beforeYear + "-" + this.yesterday;
      }
      this.$.ajax({
        url: this.$API.ajaxPath,
        type: "post",
        data: {
          interfaceName: this.interfaceName,
          methodName: "getBarChartStaticData",
          args: [type]
        },
        dataType: "json",
        success: response => {
          if (response.status == "0") {
            this.ydd = JSON.parse(response.result);
            setTimeout(() => {
              this.initZhywYdd();
            }, 100);
          }
        },
        error: xhr => {
          console.log(xhr);
        }
      });
    },

    zhywClick(tab) {
      if (tab.index == 1) {
        setTimeout(() => {
          this.getBarChartStaticDataydd("mobileSystem");
        }, 200);
      }
    }
  }
};
</script>

<style lang="less" scoped>
@import "./css/light.less";
@import "./css/blue.less";
.xtdh_padding {
  /deep/.el-tabs__header {
    padding: 0 26px;
  }
}

.gnsx-table-box /deep/ td {
  padding: 5px 0;
}

.gnsx-table-box /deep/ .el-table .cell {
  font-size: 12px;
}

.gnsx-table-box /deep/ thead tr th:first-of-type div {
  display: none;
}

.gnsx-table-box /deep/ .el-table td,
.gnsx-table-box /deep/ .el-table th {
  padding: 3px 0;
}

.theme {
  span {
    display: inline-block;
    margin-right: 10px;
  }
}
#d1 {
  height: 125px;
  display: flex;
  overflow: hidden;
  width: 100%;
}
#d12 {
  /*元素个数*207(div宽度)  动态算 828px[4个元素] 1035px[5个元素]  1242px[6个元素]  2070px[10个元素]
  用JS动态设置改值
  */
  /*先预设足够放10张图片的宽度*/
  width: 2070px;
  height: 125px;
  /*使用弹性布局排列*/
  display: flex;
  transition: all 0.3s linear 0s;
  /*再将多出来的5张图片的宽度用负边距隐藏起来*/
  margin-right: -1035px;
}
#d12 .d120 {
  height: 121px;
  z-index: 1;
}
.ddd {
  width: calc(100% - 27px / 4);
  margin-right: 9px;
}

.gnsx-hint-table {
  p {
    text-align: center;
    font-size: 13px;
    color: rgb(132, 133, 141);
    margin: 0;
    padding: 3px 0 0 0;
  }
}

/* 设置滚动条的样式 */
::-webkit-scrollbar {
  width: 7px;
}

/* 滚动槽 */
::-webkit-scrollbar-track {
  -webkit-box-shadow: inset006pxrgba(0, 0, 0, 0.4);
  border-radius: 10px;
}

/* 滚动条滑块 */
::-webkit-scrollbar-thumb {
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.2);
  -webkit-box-shadow: inset006pxrgba(0, 0, 0, 0.6);
}

// 今日受理滚动设置
.box-item {
  position: relative;
  height: 35px;
  font-size: 18px;
  font-weight: bold;
  line-height: 35px;
  text-align: center;
  list-style: none;
  color: #57a6f3;
  writing-mode: vertical-lr;
  text-orientation: upright;
  /*文字禁止编辑*/
  -moz-user-select: none;
  /*火狐*/
  -webkit-user-select: none;
  /*webkit浏览器*/
  -ms-user-select: none;
  /*IE10*/
  -khtml-user-select: none;
  /*早期浏览器*/
  user-select: none;
  /* overflow: hidden; */
}

/* 默认逗号设置 */
.mark-item {
  width: 10px;
  height: 35px;
  margin-right: 5px;
  line-height: 10px;
  font-size: 18px;
  position: relative;

  & > span {
    position: absolute;
    width: 100%;
    bottom: 0;
    writing-mode: vertical-rl;
    text-orientation: upright;
  }
}

/*滚动数字设置*/
.number-item {
  width: 25px;
  height: 35px;
  background: #fff;
  list-style: none;
  margin-right: 5px;
  background: rgba(250, 250, 250, 1);
  border-radius: 4px;
  border: 1px solid rgba(221, 221, 221, 1);

  & > span {
    position: relative;
    display: inline-block;
    margin-right: 10px;
    width: 100%;
    height: 100%;
    writing-mode: vertical-rl;
    text-orientation: upright;
    overflow: hidden;

    & > i {
      font-style: normal;
      position: absolute;
      top: 9px;
      left: 50%;
      transform: translate(-50%, 0);
      transition: transform 1s ease-in-out;
      letter-spacing: 10px;
    }
  }
}

.number-item:last-child {
  margin-right: 0;
}

.teg_flex {
  display: flex;
  justify-content: space-between;
  .tag {
    width: 48% !important;
    margin-right: 0 !important;
  }
}
.color_red {
  color: #d43030 !important;
}
.color_orange {
  color: #ff8d1a !important;
}
</style>
